cosmos 4.2.4-java → 4.3.0-java
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.travis.yml +1 -1
- data/Gemfile +1 -1
- data/Manifest.txt +12 -0
- data/autohotkey/tools/cmd_sequence.ahk +21 -20
- data/autohotkey/tools/cmd_sequence2.ahk +1 -1
- data/autohotkey/tools/config_editor.ahk +1 -1
- data/autohotkey/tools/launcher.ahk +1 -0
- data/autohotkey/tools/packet_viewer.ahk +6 -5
- data/autohotkey/tools/test_runner.ahk +8 -8
- data/bin/cosmos +37 -0
- data/bin/dart_util +0 -0
- data/data/config/item_modifiers.yaml +9 -0
- data/data/crc.txt +91 -86
- data/demo/Rakefile +2 -0
- data/demo/config/dart/Gemfile +1 -1
- data/demo/config/data/crc.txt +8 -5
- data/demo/config/system/system.txt +28 -0
- data/demo/config/system/system2.txt +21 -3
- data/demo/config/system/system_alt_ports.txt +69 -0
- data/demo/config/targets/INST/cmd_tlm/inst_tlm.txt +1 -0
- data/demo/config/tools/cmd_tlm_server/cmd_tlm_server_chain.txt +18 -0
- data/demo/procedures/cosmos_api_test.rb +18 -14
- data/demo/procedures/local_screen_example.rb +51 -0
- data/ext/cosmos/ext/cosmos_io/cosmos_io.c +32 -4
- data/ext/cosmos/ext/packet/packet.c +6 -0
- data/ext/mkrf_conf.rb +2 -2
- data/install/config/dart/Gemfile +1 -1
- data/install/config/data/crc.txt +2 -2
- data/install/config/system/system.txt +23 -1
- data/lib/cosmos/conversions.rb +2 -0
- data/lib/cosmos/conversions/packet_time_formatted_conversion.rb +38 -0
- data/lib/cosmos/conversions/packet_time_seconds_conversion.rb +38 -0
- data/lib/cosmos/core_ext/cosmos_io.rb +2 -1
- data/lib/cosmos/dart/Gemfile +1 -1
- data/lib/cosmos/dart/examples/dart_stream_client.rb +6 -2
- data/lib/cosmos/dart/lib/dart_common.rb +1 -1
- data/lib/cosmos/dart/lib/dart_database_cleaner.rb +2 -2
- data/lib/cosmos/dart/lib/dart_decommutator.rb +4 -4
- data/lib/cosmos/dart/lib/dart_importer.rb +3 -3
- data/lib/cosmos/dart/lib/dart_packet_log_writer.rb +2 -2
- data/lib/cosmos/dart/processes/dart_ingester.rb +2 -0
- data/lib/cosmos/dart/processes/dart_util.rb +4 -4
- data/lib/cosmos/dart/spec/dart/dart_reducer_manager_spec.rb +3 -3
- data/lib/cosmos/gui/dialogs/cmd_tlm_raw_dialog.rb +9 -5
- data/lib/cosmos/gui/dialogs/details_dialog.rb +29 -29
- data/lib/cosmos/gui/dialogs/exception_list_dialog.rb +1 -1
- data/lib/cosmos/gui/dialogs/find_replace_dialog.rb +3 -3
- data/lib/cosmos/gui/dialogs/interface_raw_dialog.rb +2 -2
- data/lib/cosmos/gui/dialogs/set_tlm_dialog.rb +1 -1
- data/lib/cosmos/gui/dialogs/tlm_details_dialog.rb +10 -10
- data/lib/cosmos/gui/qt.rb +10 -1
- data/lib/cosmos/gui/qt_tool.rb +17 -10
- data/lib/cosmos/gui/text/ruby_editor.rb +47 -8
- data/lib/cosmos/gui/utilities/classification_banner.rb +60 -0
- data/lib/cosmos/gui/utilities/script_module_gui.rb +26 -0
- data/lib/cosmos/interfaces.rb +1 -0
- data/lib/cosmos/interfaces/interface.rb +4 -0
- data/lib/cosmos/interfaces/protocols/ignore_packet_protocol.rb +46 -0
- data/lib/cosmos/interfaces/protocols/preidentified_protocol.rb +68 -23
- data/lib/cosmos/packet_logs/packet_log_reader.rb +69 -26
- data/lib/cosmos/packet_logs/packet_log_writer.rb +13 -1
- data/lib/cosmos/packets/commands.rb +5 -1
- data/lib/cosmos/packets/packet.rb +36 -2
- data/lib/cosmos/packets/packet_config.rb +0 -1
- data/lib/cosmos/packets/parsers/format_string_parser.rb +0 -1
- data/lib/cosmos/packets/parsers/xtce_parser.rb +1 -1
- data/lib/cosmos/packets/telemetry.rb +4 -0
- data/lib/cosmos/script/api_shared.rb +2 -0
- data/lib/cosmos/script/limits.rb +4 -0
- data/lib/cosmos/script/script.rb +27 -11
- data/lib/cosmos/script/telemetry.rb +3 -1
- data/lib/cosmos/script/tools.rb +18 -8
- data/lib/cosmos/system/system.rb +21 -0
- data/lib/cosmos/tools/cmd_extractor/cmd_extractor.rb +26 -24
- data/lib/cosmos/tools/cmd_sender/cmd_sender.rb +29 -29
- data/lib/cosmos/tools/cmd_sequence/cmd_sequence.rb +65 -40
- data/lib/cosmos/tools/cmd_sequence/sequence_item.rb +6 -6
- data/lib/cosmos/tools/cmd_tlm_server/api.rb +13 -0
- data/lib/cosmos/tools/cmd_tlm_server/cmd_tlm_server.rb +12 -9
- data/lib/cosmos/tools/cmd_tlm_server/cmd_tlm_server_config.rb +7 -1
- data/lib/cosmos/tools/cmd_tlm_server/cmd_tlm_server_gui.rb +8 -8
- data/lib/cosmos/tools/cmd_tlm_server/commanding.rb +13 -2
- data/lib/cosmos/tools/cmd_tlm_server/gui/interfaces_tab.rb +2 -2
- data/lib/cosmos/tools/cmd_tlm_server/gui/logging_tab.rb +13 -13
- data/lib/cosmos/tools/cmd_tlm_server/gui/packets_tab.rb +4 -4
- data/lib/cosmos/tools/cmd_tlm_server/gui/status_tab.rb +8 -8
- data/lib/cosmos/tools/cmd_tlm_server/gui/targets_tab.rb +5 -5
- data/lib/cosmos/tools/cmd_tlm_server/interface_thread.rb +35 -20
- data/lib/cosmos/tools/cmd_tlm_server/replay_backend.rb +15 -11
- data/lib/cosmos/tools/config_editor/config_editor.rb +69 -69
- data/lib/cosmos/tools/data_viewer/data_viewer.rb +42 -38
- data/lib/cosmos/tools/data_viewer/data_viewer_component.rb +1 -0
- data/lib/cosmos/tools/data_viewer/dump_component.rb +1 -0
- data/lib/cosmos/tools/handbook_creator/handbook_creator.rb +4 -4
- data/lib/cosmos/tools/launcher/launcher.rb +1 -1
- data/lib/cosmos/tools/limits_monitor/limits_monitor.rb +28 -24
- data/lib/cosmos/tools/opengl_builder/opengl_builder.rb +42 -42
- data/lib/cosmos/tools/packet_viewer/packet_viewer.rb +56 -53
- data/lib/cosmos/tools/script_runner/script_runner.rb +112 -95
- data/lib/cosmos/tools/script_runner/script_runner_frame.rb +48 -30
- data/lib/cosmos/tools/table_manager/table_manager.rb +42 -42
- data/lib/cosmos/tools/test_runner/test_runner.rb +45 -27
- data/lib/cosmos/tools/test_runner/test_runner_chooser.rb +3 -3
- data/lib/cosmos/tools/tlm_extractor/tlm_extractor.rb +45 -45
- data/lib/cosmos/tools/tlm_extractor/tlm_extractor_config.rb +4 -4
- data/lib/cosmos/tools/tlm_grapher/data_object_adders/xy_data_object_adder.rb +3 -3
- data/lib/cosmos/tools/tlm_grapher/data_object_editors/housekeeping_data_object_editor.rb +7 -7
- data/lib/cosmos/tools/tlm_grapher/data_object_editors/xy_data_object_editor.rb +10 -10
- data/lib/cosmos/tools/tlm_grapher/data_objects/housekeeping_data_object.rb +10 -3
- data/lib/cosmos/tools/tlm_grapher/data_objects/xy_data_object.rb +6 -6
- data/lib/cosmos/tools/tlm_grapher/tabbed_plots/overview_tabbed_plots.rb +14 -14
- data/lib/cosmos/tools/tlm_grapher/tabbed_plots_tool/tabbed_plots_tool.rb +83 -83
- data/lib/cosmos/tools/tlm_viewer/screen.rb +73 -13
- data/lib/cosmos/tools/tlm_viewer/tlm_viewer.rb +15 -15
- data/lib/cosmos/tools/tlm_viewer/widgets.rb +1 -0
- data/lib/cosmos/tools/tlm_viewer/widgets/canvasellipse_widget.rb +40 -0
- data/lib/cosmos/tools/tlm_viewer/widgets/timegraph_widget.rb +1 -1
- data/lib/cosmos/tools/tlm_viewer/widgets/widget.rb +6 -1
- data/lib/cosmos/top_level.rb +14 -1
- data/lib/cosmos/version.rb +5 -5
- data/lib/cosmos/win32/excel.rb +63 -12
- data/make_gems.sh +10 -0
- data/spec/conversions/packet_time_formatted_conversion_spec.rb +58 -0
- data/spec/conversions/packet_time_seconds_conversion_spec.rb +60 -0
- data/spec/interfaces/protocols/ignore_packet_protocol_spec.rb +243 -0
- data/spec/interfaces/protocols/preidentified_protocol_spec.rb +227 -4
- data/spec/io/serial_driver_spec.rb +15 -13
- data/spec/packet_logs/packet_log_reader_spec.rb +72 -17
- data/spec/packets/packet_config_spec.rb +5 -16
- data/spec/packets/parsers/format_string_parser_spec.rb +0 -11
- data/spec/packets/parsers/macro_parser_spec.rb +36 -36
- data/spec/packets/parsers/state_parser_spec.rb +36 -0
- data/spec/packets/telemetry_spec.rb +11 -9
- data/spec/script/script_spec.rb +2 -3
- data/spec/script/scripting_spec.rb +2 -1
- data/spec/script/tools_spec.rb +0 -1
- data/spec/tools/cmd_tlm_server/api_spec.rb +28 -20
- data/spec/tools/cmd_tlm_server/cmd_tlm_server_config_spec.rb +33 -0
- data/spec/tools/cmd_tlm_server/commanding_spec.rb +25 -1
- data/spec/tools/cmd_tlm_server/interface_thread_spec.rb +15 -0
- data/tasks/gemfile_stats.rake +3 -2
- metadata +14 -2
|
@@ -20,7 +20,7 @@ module Cosmos
|
|
|
20
20
|
DART_REDUCTION_OPTIONS = [:NONE, :MINUTE, :HOUR, :DAY]
|
|
21
21
|
DART_REDUCED_TYPES = [:AVG, :MIN, :MAX, :STDDEV]
|
|
22
22
|
COLUMN_MODES = [:NORMAL, :SHARE_ALL_COLUMNS, :SHARE_INDIV_COLUMNS, :FULL_COLUMN_NAMES]
|
|
23
|
-
DEFAULT_UNIQUE_IGNORED = ['RECEIVED_TIMEFORMATTED', 'RECEIVED_TIMESECONDS']
|
|
23
|
+
DEFAULT_UNIQUE_IGNORED = ['PACKET_TIMEFORMATTED', 'PACKET_TIMESECONDS', 'RECEIVED_TIMEFORMATTED', 'RECEIVED_TIMESECONDS']
|
|
24
24
|
ITEM = 'ITEM'.freeze
|
|
25
25
|
TEXT = 'TEXT'.freeze
|
|
26
26
|
|
|
@@ -257,7 +257,7 @@ module Cosmos
|
|
|
257
257
|
else
|
|
258
258
|
raise "Unknown Dart Reduction: #{dart_reduction}"
|
|
259
259
|
end
|
|
260
|
-
|
|
260
|
+
|
|
261
261
|
if params.length == 5
|
|
262
262
|
dart_reduced_type = :AVG
|
|
263
263
|
else
|
|
@@ -416,8 +416,8 @@ module Cosmos
|
|
|
416
416
|
target_timestamp_mapping = @packet_timestamp_mapping[packet.target_name]
|
|
417
417
|
end
|
|
418
418
|
previous_timestamp = target_timestamp_mapping[packet.packet_name]
|
|
419
|
-
return if previous_timestamp and (packet.
|
|
420
|
-
target_timestamp_mapping[packet.packet_name] = packet.
|
|
419
|
+
return if previous_timestamp and (packet.packet_time - previous_timestamp) < @downsample_seconds
|
|
420
|
+
target_timestamp_mapping[packet.packet_name] = packet.packet_time
|
|
421
421
|
end
|
|
422
422
|
|
|
423
423
|
# Create a new row
|
|
@@ -47,7 +47,7 @@ module Cosmos
|
|
|
47
47
|
# Chooser for x item
|
|
48
48
|
x_item_names = @telemetry_chooser.item_names
|
|
49
49
|
@x_item_name = ComboboxChooser.new(self, 'X Item:', x_item_names)
|
|
50
|
-
@x_item_name.set_current('
|
|
50
|
+
@x_item_name.set_current('PACKET_TIMESECONDS')
|
|
51
51
|
@overall_frame.addWidget(@x_item_name)
|
|
52
52
|
|
|
53
53
|
# Button to add data object
|
|
@@ -67,7 +67,7 @@ module Cosmos
|
|
|
67
67
|
@telemetry_chooser.update
|
|
68
68
|
x_item_names = @telemetry_chooser.item_names
|
|
69
69
|
@x_item_name.update_items(x_item_names, false)
|
|
70
|
-
@x_item_name.set_current('
|
|
70
|
+
@x_item_name.set_current('PACKET_TIMESECONDS')
|
|
71
71
|
end
|
|
72
72
|
|
|
73
73
|
# Adds a data object when the add button is pressed
|
|
@@ -87,7 +87,7 @@ module Cosmos
|
|
|
87
87
|
def packet_changed_callback(target_name = nil, packet_name = nil)
|
|
88
88
|
x_item_names = @telemetry_chooser.item_names
|
|
89
89
|
@x_item_name.update_items(x_item_names, false)
|
|
90
|
-
@x_item_name.set_current('
|
|
90
|
+
@x_item_name.set_current('PACKET_TIMESECONDS')
|
|
91
91
|
end
|
|
92
92
|
|
|
93
93
|
end # class XyDataObjectAdder
|
|
@@ -75,7 +75,7 @@ module Cosmos
|
|
|
75
75
|
if data_object.time_item_name
|
|
76
76
|
@time_item_name.set_current(data_object.time_item_name)
|
|
77
77
|
else
|
|
78
|
-
@time_item_name.set_current('
|
|
78
|
+
@time_item_name.set_current('PACKET_TIMESECONDS')
|
|
79
79
|
end
|
|
80
80
|
local_layout.addWidget(@time_item_name)
|
|
81
81
|
|
|
@@ -197,11 +197,11 @@ module Cosmos
|
|
|
197
197
|
dart_reductions = HousekeepingDataObject::DART_REDUCTIONS.map {|x| x.to_s}
|
|
198
198
|
dart_reductions.delete(data_object.dart_reduction.to_s)
|
|
199
199
|
dart_reductions.unshift(data_object.dart_reduction.to_s)
|
|
200
|
-
@dart_reduction.update_items(dart_reductions, false)
|
|
200
|
+
@dart_reduction.update_items(dart_reductions, false)
|
|
201
201
|
dart_reduced_types = HousekeepingDataObject::DART_REDUCED_TYPES.map {|x| x.to_s}
|
|
202
202
|
dart_reduced_types.delete(data_object.dart_reduced_type.to_s)
|
|
203
203
|
dart_reduced_types.unshift(data_object.dart_reduced_type.to_s)
|
|
204
|
-
@dart_reduced_type.update_items(dart_reduced_types, false)
|
|
204
|
+
@dart_reduced_type.update_items(dart_reduced_types, false)
|
|
205
205
|
|
|
206
206
|
packet, item = System.telemetry.packet_and_item(data_object.target_name,
|
|
207
207
|
data_object.packet_name,
|
|
@@ -211,7 +211,7 @@ module Cosmos
|
|
|
211
211
|
@item_array_index.show
|
|
212
212
|
else
|
|
213
213
|
@array_item = false
|
|
214
|
-
@item_array_index.hide
|
|
214
|
+
@item_array_index.hide
|
|
215
215
|
end
|
|
216
216
|
|
|
217
217
|
end
|
|
@@ -227,11 +227,11 @@ module Cosmos
|
|
|
227
227
|
dart_reductions = HousekeepingDataObject::DART_REDUCTIONS.map {|x| x.to_s}
|
|
228
228
|
dart_reductions.delete(data_object.dart_reduction.to_s)
|
|
229
229
|
dart_reductions.unshift(data_object.dart_reduction.to_s)
|
|
230
|
-
@dart_reduction.update_items(dart_reductions, false)
|
|
230
|
+
@dart_reduction.update_items(dart_reductions, false)
|
|
231
231
|
dart_reduced_types = HousekeepingDataObject::DART_REDUCED_TYPES.map {|x| x.to_s}
|
|
232
232
|
dart_reduced_types.delete(data_object.dart_reduced_type.to_s)
|
|
233
233
|
dart_reduced_types.unshift(data_object.dart_reduced_type.to_s)
|
|
234
|
-
@dart_reduced_type.update_items(dart_reduced_types, false)
|
|
234
|
+
@dart_reduced_type.update_items(dart_reduced_types, false)
|
|
235
235
|
|
|
236
236
|
packet, item = System.telemetry.packet_and_item(data_object.target_name,
|
|
237
237
|
data_object.packet_name,
|
|
@@ -241,7 +241,7 @@ module Cosmos
|
|
|
241
241
|
@item_array_index.show
|
|
242
242
|
else
|
|
243
243
|
@array_item = false
|
|
244
|
-
@item_array_index.hide
|
|
244
|
+
@item_array_index.hide
|
|
245
245
|
end
|
|
246
246
|
end
|
|
247
247
|
|
|
@@ -39,9 +39,9 @@ module Cosmos
|
|
|
39
39
|
packet = System.telemetry.first_non_hidden
|
|
40
40
|
data_object.target_name = packet.target_name
|
|
41
41
|
data_object.packet_name = packet.packet_name
|
|
42
|
-
data_object.y_item_name = '
|
|
43
|
-
data_object.x_item_name = '
|
|
44
|
-
data_object.time_item_name = '
|
|
42
|
+
data_object.y_item_name = 'PACKET_TIMESECONDS'
|
|
43
|
+
data_object.x_item_name = 'PACKET_TIMESECONDS'
|
|
44
|
+
data_object.time_item_name = 'PACKET_TIMESECONDS'
|
|
45
45
|
end
|
|
46
46
|
super(data_object)
|
|
47
47
|
|
|
@@ -123,7 +123,7 @@ module Cosmos
|
|
|
123
123
|
data_object.y_value_type = @y_value_type.symbol
|
|
124
124
|
data_object.x_value_type = @x_value_type.symbol
|
|
125
125
|
data_object.dart_reduction = @dart_reduction.symbol
|
|
126
|
-
data_object.dart_reduced_type = @dart_reduced_type.symbol
|
|
126
|
+
data_object.dart_reduced_type = @dart_reduced_type.symbol
|
|
127
127
|
data_object
|
|
128
128
|
end
|
|
129
129
|
|
|
@@ -158,11 +158,11 @@ module Cosmos
|
|
|
158
158
|
dart_reductions = HousekeepingDataObject::DART_REDUCTIONS.map {|x| x.to_s}
|
|
159
159
|
dart_reductions.delete(data_object.dart_reduction.to_s)
|
|
160
160
|
dart_reductions.unshift(data_object.dart_reduction.to_s)
|
|
161
|
-
@dart_reduction.update_items(dart_reductions, false)
|
|
161
|
+
@dart_reduction.update_items(dart_reductions, false)
|
|
162
162
|
dart_reduced_types = HousekeepingDataObject::DART_REDUCED_TYPES.map {|x| x.to_s}
|
|
163
163
|
dart_reduced_types.delete(data_object.dart_reduced_type.to_s)
|
|
164
164
|
dart_reduced_types.unshift(data_object.dart_reduced_type.to_s)
|
|
165
|
-
@dart_reduced_type.update_items(dart_reduced_types, false)
|
|
165
|
+
@dart_reduced_type.update_items(dart_reduced_types, false)
|
|
166
166
|
end
|
|
167
167
|
|
|
168
168
|
# Handles the y item name changing
|
|
@@ -178,11 +178,11 @@ module Cosmos
|
|
|
178
178
|
dart_reductions = HousekeepingDataObject::DART_REDUCTIONS.map {|x| x.to_s}
|
|
179
179
|
dart_reductions.delete(data_object.dart_reduction.to_s)
|
|
180
180
|
dart_reductions.unshift(data_object.dart_reduction.to_s)
|
|
181
|
-
@dart_reduction.update_items(dart_reductions, false)
|
|
181
|
+
@dart_reduction.update_items(dart_reductions, false)
|
|
182
182
|
dart_reduced_types = HousekeepingDataObject::DART_REDUCED_TYPES.map {|x| x.to_s}
|
|
183
183
|
dart_reduced_types.delete(data_object.dart_reduced_type.to_s)
|
|
184
184
|
dart_reduced_types.unshift(data_object.dart_reduced_type.to_s)
|
|
185
|
-
@dart_reduced_type.update_items(dart_reduced_types, false)
|
|
185
|
+
@dart_reduced_type.update_items(dart_reduced_types, false)
|
|
186
186
|
end
|
|
187
187
|
|
|
188
188
|
# Handles the x item name changing
|
|
@@ -197,11 +197,11 @@ module Cosmos
|
|
|
197
197
|
dart_reductions = XyDataObject::DART_REDUCTIONS.map {|x| x.to_s}
|
|
198
198
|
dart_reductions.delete(data_object.dart_reduction.to_s)
|
|
199
199
|
dart_reductions.unshift(data_object.dart_reduction.to_s)
|
|
200
|
-
@dart_reduction.update_items(dart_reductions, false)
|
|
200
|
+
@dart_reduction.update_items(dart_reductions, false)
|
|
201
201
|
dart_reduced_types = XyDataObject::DART_REDUCED_TYPES.map {|x| x.to_s}
|
|
202
202
|
dart_reduced_types.delete(data_object.dart_reduced_type.to_s)
|
|
203
203
|
dart_reduced_types.unshift(data_object.dart_reduced_type.to_s)
|
|
204
|
-
@dart_reduced_type.update_items(dart_reduced_types, false)
|
|
204
|
+
@dart_reduced_type.update_items(dart_reduced_types, false)
|
|
205
205
|
end
|
|
206
206
|
end
|
|
207
207
|
|
|
@@ -255,8 +255,15 @@ module Cosmos
|
|
|
255
255
|
|
|
256
256
|
case @analysis
|
|
257
257
|
when :NONE
|
|
258
|
-
|
|
259
|
-
@
|
|
258
|
+
# Support out of order x_values with no analysis
|
|
259
|
+
if @x_values.empty? or @x_values[-1] <= x_value or !@x_values.respond_to? :bsearch_index
|
|
260
|
+
@x_values << x_value
|
|
261
|
+
@y_values << y_value + @y_offset
|
|
262
|
+
else
|
|
263
|
+
loc = @x_values.bsearch_index{|x| x > x_value}
|
|
264
|
+
@x_values.insert(loc, x_value)
|
|
265
|
+
@y_values.insert(loc, y_value + @y_offset)
|
|
266
|
+
end
|
|
260
267
|
@plot.redraw_needed = true
|
|
261
268
|
|
|
262
269
|
when :DIFFERENCE, :ALLAN_DEV
|
|
@@ -429,7 +436,7 @@ module Cosmos
|
|
|
429
436
|
@value_type = :CONVERTED unless during_configuration
|
|
430
437
|
end
|
|
431
438
|
|
|
432
|
-
@time_item_name = '
|
|
439
|
+
@time_item_name = 'PACKET_TIMESECONDS' unless @time_item_name
|
|
433
440
|
|
|
434
441
|
# Update limits lines
|
|
435
442
|
self.show_limits_lines = @show_limits_lines
|
|
@@ -99,7 +99,7 @@ module Cosmos
|
|
|
99
99
|
string << " X_VALUE_TYPE #{@x_value_type}\n"
|
|
100
100
|
string << " Y_VALUE_TYPE #{@y_value_type}\n"
|
|
101
101
|
string << " DART_REDUCTION #{@dart_reduction}\n"
|
|
102
|
-
string << " DART_REDUCED_TYPE #{@dart_reduced_type}\n"
|
|
102
|
+
string << " DART_REDUCED_TYPE #{@dart_reduced_type}\n"
|
|
103
103
|
string
|
|
104
104
|
end # def configuration_string
|
|
105
105
|
|
|
@@ -184,7 +184,7 @@ module Cosmos
|
|
|
184
184
|
else
|
|
185
185
|
raise ArgumentError, "Unknown DART_REDUCTION value: #{dart_reduction}"
|
|
186
186
|
end
|
|
187
|
-
|
|
187
|
+
|
|
188
188
|
when 'DART_REDUCED_TYPE'
|
|
189
189
|
# Expect 1 parameter
|
|
190
190
|
parser.verify_num_parameters(1, 1, "DART_REDUCED_TYPE <AVG, MIN, MAX, STDDEV>")
|
|
@@ -193,7 +193,7 @@ module Cosmos
|
|
|
193
193
|
@dart_reduced_type = dart_reduced_type
|
|
194
194
|
else
|
|
195
195
|
raise ArgumentError, "Unknown DART_REDUCED_TYPE value: #{dart_reduced_type}"
|
|
196
|
-
end
|
|
196
|
+
end
|
|
197
197
|
|
|
198
198
|
else
|
|
199
199
|
# Unknown keywords are passed to parent data object
|
|
@@ -263,7 +263,7 @@ module Cosmos
|
|
|
263
263
|
prune_to_max_points_saved()
|
|
264
264
|
rescue Exception => error
|
|
265
265
|
handle_process_exception(error, "#{@target_name} #{@packet_name} #{@x_item_name} or #{@y_item_name}")
|
|
266
|
-
end
|
|
266
|
+
end
|
|
267
267
|
end
|
|
268
268
|
|
|
269
269
|
# Returns the name of this data object
|
|
@@ -305,7 +305,7 @@ module Cosmos
|
|
|
305
305
|
data_object.x_value_type = @x_value_type
|
|
306
306
|
data_object.y_value_type = @y_value_type
|
|
307
307
|
data_object.dart_reduction = @dart_reduction
|
|
308
|
-
data_object.dart_reduced_type = @dart_reduced_type
|
|
308
|
+
data_object.dart_reduced_type = @dart_reduced_type
|
|
309
309
|
data_object
|
|
310
310
|
end
|
|
311
311
|
|
|
@@ -351,7 +351,7 @@ module Cosmos
|
|
|
351
351
|
@y_value_type = :CONVERTED unless @during_configuration
|
|
352
352
|
end
|
|
353
353
|
|
|
354
|
-
@time_item_name = '
|
|
354
|
+
@time_item_name = 'PACKET_TIMESECONDS' if !@time_item_name
|
|
355
355
|
end
|
|
356
356
|
|
|
357
357
|
# Sets time item
|
|
@@ -324,9 +324,9 @@ module Cosmos
|
|
|
324
324
|
end
|
|
325
325
|
if plot
|
|
326
326
|
@tabbed_plots_config.add_plot(tab_index, plot)
|
|
327
|
-
@status_bar.showMessage(
|
|
327
|
+
@status_bar.showMessage("Add Plot Succeeded")
|
|
328
328
|
else
|
|
329
|
-
@status_bar.showMessage(
|
|
329
|
+
@status_bar.showMessage("Add Plot Canceled")
|
|
330
330
|
return false
|
|
331
331
|
end
|
|
332
332
|
|
|
@@ -399,7 +399,7 @@ module Cosmos
|
|
|
399
399
|
tab.gui_layout = layout
|
|
400
400
|
#~ tab.gui_layout.connect(SEL_RIGHTBUTTONRELEASE, method(:handle_plot_right_button_release))
|
|
401
401
|
|
|
402
|
-
@status_bar.showMessage(
|
|
402
|
+
@status_bar.showMessage("Plot Deleted")
|
|
403
403
|
@config_modified_callback.call() if @config_modified_callback
|
|
404
404
|
else
|
|
405
405
|
Qt::MessageBox.information(self, 'Information', 'Please select a plot')
|
|
@@ -434,11 +434,11 @@ module Cosmos
|
|
|
434
434
|
plot_editor.dispose
|
|
435
435
|
if plot
|
|
436
436
|
plot.gui_object.update(true)
|
|
437
|
-
@status_bar.showMessage(
|
|
437
|
+
@status_bar.showMessage("Plot Edited")
|
|
438
438
|
edited = true
|
|
439
439
|
@config_modified_callback.call() if @config_modified_callback
|
|
440
440
|
else
|
|
441
|
-
@status_bar.showMessage(
|
|
441
|
+
@status_bar.showMessage("Plot Edit Canceled")
|
|
442
442
|
end
|
|
443
443
|
end
|
|
444
444
|
|
|
@@ -548,7 +548,7 @@ module Cosmos
|
|
|
548
548
|
data_object = data_object_editor.execute
|
|
549
549
|
data_object_editor.dispose
|
|
550
550
|
unless data_object
|
|
551
|
-
@status_bar.showMessage(
|
|
551
|
+
@status_bar.showMessage("Add Data Object Canceled")
|
|
552
552
|
return false
|
|
553
553
|
end
|
|
554
554
|
end
|
|
@@ -566,7 +566,7 @@ module Cosmos
|
|
|
566
566
|
# Update data object list
|
|
567
567
|
fill_data_object_list_for_plot(@tabbed_plots_config.tabs[tab_index].plots[plot_index])
|
|
568
568
|
|
|
569
|
-
@status_bar.showMessage(
|
|
569
|
+
@status_bar.showMessage("Add Data Object Succeeded")
|
|
570
570
|
@config_modified_callback.call() if @config_modified_callback
|
|
571
571
|
return true
|
|
572
572
|
end # def add_data_object
|
|
@@ -618,11 +618,11 @@ module Cosmos
|
|
|
618
618
|
data_object_editor.dispose
|
|
619
619
|
if data_object
|
|
620
620
|
@tabbed_plots_config.edit_data_object(tab_index, plot_index, data_object_idx, data_object)
|
|
621
|
-
@status_bar.showMessage(
|
|
621
|
+
@status_bar.showMessage("Data Object(s) Edited")
|
|
622
622
|
edited = true
|
|
623
623
|
@config_modified_callback.call() if @config_modified_callback
|
|
624
624
|
else
|
|
625
|
-
@status_bar.showMessage(
|
|
625
|
+
@status_bar.showMessage("Edit Data Object Canceled")
|
|
626
626
|
end
|
|
627
627
|
end
|
|
628
628
|
|
|
@@ -651,7 +651,7 @@ module Cosmos
|
|
|
651
651
|
data_object = @tabbed_plots_config.duplicate_data_object(tab_index, plot_index, data_object_idx)
|
|
652
652
|
data_object.color = get_free_color(@tabbed_plots_config.tabs[tab_index]) unless data_object.assigned_color
|
|
653
653
|
end
|
|
654
|
-
@status_bar.showMessage(
|
|
654
|
+
@status_bar.showMessage("Data Object(s) Duplicated")
|
|
655
655
|
|
|
656
656
|
plot.gui_object.update(true)
|
|
657
657
|
fill_data_object_list_for_plot(@tabbed_plots_config.tabs[tab_index].plots[plot_index])
|
|
@@ -701,7 +701,7 @@ module Cosmos
|
|
|
701
701
|
@tabbed_plots_config.reset_data_objects(tab_index, plot_index, data_object_idx)
|
|
702
702
|
end
|
|
703
703
|
redraw_plots(true, true)
|
|
704
|
-
@status_bar.showMessage(
|
|
704
|
+
@status_bar.showMessage("Data Object(s) Reset")
|
|
705
705
|
end
|
|
706
706
|
end
|
|
707
707
|
|
|
@@ -954,9 +954,9 @@ module Cosmos
|
|
|
954
954
|
"Are you sure you want to delete the selected data objects?",
|
|
955
955
|
Qt::MessageBox::Yes | Qt::MessageBox::No, Qt::MessageBox::No)
|
|
956
956
|
if result == Qt::MessageBox::No
|
|
957
|
-
otp.status_bar.showMessage(
|
|
957
|
+
otp.status_bar.showMessage("Data Object Deletion Canceled")
|
|
958
958
|
else
|
|
959
|
-
otp.status_bar.showMessage(
|
|
959
|
+
otp.status_bar.showMessage("Data Object Deleted")
|
|
960
960
|
otp.delete_data_object()
|
|
961
961
|
end
|
|
962
962
|
otp.resume() unless paused
|
|
@@ -973,7 +973,7 @@ module Cosmos
|
|
|
973
973
|
self,
|
|
974
974
|
SLOT('data_object_context_menu(const QPoint&)'))
|
|
975
975
|
@data_object_list.connect(SIGNAL('itemClicked(QListWidgetItem*)')) do
|
|
976
|
-
@status_bar.showMessage(
|
|
976
|
+
@status_bar.showMessage("Drag and drop to reorder. Items are drawn in order from top to bottom.")
|
|
977
977
|
end
|
|
978
978
|
@data_object_list.addItemColor('No Plot Selected')
|
|
979
979
|
@tabbed_plots_left_frame.addWidget(@data_object_list)
|
|
@@ -36,7 +36,7 @@ module Cosmos
|
|
|
36
36
|
@base_title = self.windowTitle
|
|
37
37
|
Cosmos.load_cosmos_icon("tlm_grapher.png")
|
|
38
38
|
|
|
39
|
-
statusBar.showMessage(
|
|
39
|
+
statusBar.showMessage("") # Show blank message to initialize status bar
|
|
40
40
|
|
|
41
41
|
initialize_actions()
|
|
42
42
|
initialize_menus(options)
|
|
@@ -91,131 +91,131 @@ module Cosmos
|
|
|
91
91
|
super()
|
|
92
92
|
|
|
93
93
|
# File Menu Actions
|
|
94
|
-
@file_process = Qt::Action.new(
|
|
95
|
-
@file_process_keyseq = Qt::KeySequence.new(
|
|
94
|
+
@file_process = Qt::Action.new('&Open Log', self)
|
|
95
|
+
@file_process_keyseq = Qt::KeySequence.new('Ctrl+O')
|
|
96
96
|
@file_process.shortcut = @file_process_keyseq
|
|
97
|
-
@file_process.statusTip =
|
|
97
|
+
@file_process.statusTip = 'Open Log File'
|
|
98
98
|
@file_process.connect(SIGNAL('triggered()')) { on_file_process_log() }
|
|
99
99
|
|
|
100
|
-
@file_dart = Qt::Action.new(
|
|
101
|
-
@file_dart_keyseq = Qt::KeySequence.new(
|
|
100
|
+
@file_dart = Qt::Action.new('&Query DART Database', self)
|
|
101
|
+
@file_dart_keyseq = Qt::KeySequence.new('Ctrl+D')
|
|
102
102
|
@file_dart.shortcut = @file_dart_keyseq
|
|
103
|
-
@file_dart.statusTip =
|
|
103
|
+
@file_dart.statusTip = 'Query DART Database'
|
|
104
104
|
@file_dart.connect(SIGNAL('triggered()')) { on_file_dart() }
|
|
105
105
|
|
|
106
|
-
@file_load = Qt::Action.new(Cosmos.get_icon('open.png'),
|
|
107
|
-
@file_load.statusTip =
|
|
106
|
+
@file_load = Qt::Action.new(Cosmos.get_icon('open.png'), '&Load Config', self)
|
|
107
|
+
@file_load.statusTip = 'Load Saved Configuration'
|
|
108
108
|
@file_load.connect(SIGNAL('triggered()')) { on_file_load_config() }
|
|
109
109
|
|
|
110
|
-
@file_save = Qt::Action.new(Cosmos.get_icon('save.png'),
|
|
111
|
-
@file_save_keyseq = Qt::KeySequence.new(
|
|
110
|
+
@file_save = Qt::Action.new(Cosmos.get_icon('save.png'), '&Save Config', self)
|
|
111
|
+
@file_save_keyseq = Qt::KeySequence.new('Ctrl+S')
|
|
112
112
|
@file_save.shortcut = @file_save_keyseq
|
|
113
|
-
@file_save.statusTip =
|
|
113
|
+
@file_save.statusTip = 'Save Current Configuration'
|
|
114
114
|
@file_save.connect(SIGNAL('triggered()')) { on_file_save_config() }
|
|
115
115
|
|
|
116
|
-
@file_screenshot = Qt::Action.new(Cosmos.get_icon('screenshot.png'),
|
|
117
|
-
@file_screenshot.statusTip =
|
|
116
|
+
@file_screenshot = Qt::Action.new(Cosmos.get_icon('screenshot.png'), 'Screensho&t', self)
|
|
117
|
+
@file_screenshot.statusTip = 'Screenshot of Application'
|
|
118
118
|
@file_screenshot.connect(SIGNAL('triggered()')) { on_file_screenshot() }
|
|
119
119
|
|
|
120
|
-
@replay_action = Qt::Action.new(
|
|
121
|
-
@replay_action.statusTip =
|
|
120
|
+
@replay_action = Qt::Action.new('Toggle Replay Mode', self)
|
|
121
|
+
@replay_action.statusTip = 'Toggle Replay Mode'
|
|
122
122
|
@replay_action.connect(SIGNAL('triggered()')) { toggle_replay_mode() }
|
|
123
123
|
|
|
124
124
|
# Tab Menu Actions
|
|
125
|
-
@tab_add = Qt::Action.new(Cosmos.get_icon('add_tab.png'),
|
|
126
|
-
@tab_add.statusTip =
|
|
125
|
+
@tab_add = Qt::Action.new(Cosmos.get_icon('add_tab.png'), '&Add Tab', self)
|
|
126
|
+
@tab_add.statusTip = 'Add New Tab'
|
|
127
127
|
@tab_add.connect(SIGNAL('triggered()')) { on_tab_add() }
|
|
128
128
|
|
|
129
|
-
@tab_delete = Qt::Action.new(Cosmos.get_icon('delete_tab.png'),
|
|
130
|
-
@tab_delete.statusTip =
|
|
129
|
+
@tab_delete = Qt::Action.new(Cosmos.get_icon('delete_tab.png'), '&Delete Tab', self)
|
|
130
|
+
@tab_delete.statusTip = 'Delete Active Tab'
|
|
131
131
|
@tab_delete.connect(SIGNAL('triggered()')) { on_tab_delete() }
|
|
132
132
|
|
|
133
|
-
@tab_edit = Qt::Action.new(Cosmos.get_icon('edit_tab.png'),
|
|
134
|
-
@tab_edit.statusTip =
|
|
133
|
+
@tab_edit = Qt::Action.new(Cosmos.get_icon('edit_tab.png'), '&Edit Tab', self)
|
|
134
|
+
@tab_edit.statusTip = 'Edit Active Tab'
|
|
135
135
|
@tab_edit.connect(SIGNAL('triggered()')) { on_tab_edit() }
|
|
136
136
|
|
|
137
|
-
@tab_screenshot = Qt::Action.new(Cosmos.get_icon('screenshot.png'),
|
|
138
|
-
@tab_screenshot.statusTip =
|
|
137
|
+
@tab_screenshot = Qt::Action.new(Cosmos.get_icon('screenshot.png'), '&Screenshot Tab', self)
|
|
138
|
+
@tab_screenshot.statusTip = 'Screenshot of Active Tab'
|
|
139
139
|
@tab_screenshot.connect(SIGNAL('triggered()')) { on_tab_screenshot() }
|
|
140
140
|
|
|
141
|
-
@tab_export = Qt::Action.new(
|
|
142
|
-
@tab_export.statusTip =
|
|
141
|
+
@tab_export = Qt::Action.new('E&xport Tab Data Objects', self)
|
|
142
|
+
@tab_export.statusTip = 'Export Tab Data Object(s)'
|
|
143
143
|
@tab_export.connect(SIGNAL('triggered()')) { on_tab_export() }
|
|
144
144
|
|
|
145
|
-
@tab_reset = Qt::Action.new(
|
|
146
|
-
@tab_reset.statusTip =
|
|
145
|
+
@tab_reset = Qt::Action.new('&Reset Tab Data Objects', self)
|
|
146
|
+
@tab_reset.statusTip = 'Reset Tab Data Object(s)'
|
|
147
147
|
@tab_reset.connect(SIGNAL('triggered()')) { on_tab_reset() }
|
|
148
148
|
|
|
149
149
|
# Plot Menu Actions
|
|
150
|
-
@plot_add = Qt::Action.new(Cosmos.get_icon('add_plot.png'),
|
|
151
|
-
@plot_add.statusTip =
|
|
150
|
+
@plot_add = Qt::Action.new(Cosmos.get_icon('add_plot.png'), '&Add Plot', self)
|
|
151
|
+
@plot_add.statusTip = 'Add New Plot'
|
|
152
152
|
@plot_add.connect(SIGNAL('triggered()')) { on_plot_add() }
|
|
153
153
|
|
|
154
|
-
@plot_delete = Qt::Action.new(Cosmos.get_icon('delete_plot.png'),
|
|
155
|
-
@plot_delete.statusTip =
|
|
154
|
+
@plot_delete = Qt::Action.new(Cosmos.get_icon('delete_plot.png'), '&Delete Plot', self)
|
|
155
|
+
@plot_delete.statusTip = 'Delete Selected Plot'
|
|
156
156
|
@plot_delete.connect(SIGNAL('triggered()')) { on_plot_delete() }
|
|
157
157
|
|
|
158
|
-
@plot_edit = Qt::Action.new(Cosmos.get_icon('edit_plot.png'),
|
|
159
|
-
@plot_edit.statusTip =
|
|
158
|
+
@plot_edit = Qt::Action.new(Cosmos.get_icon('edit_plot.png'), '&Edit Plot', self)
|
|
159
|
+
@plot_edit.statusTip = 'Edit Selected Plot'
|
|
160
160
|
@plot_edit.connect(SIGNAL('triggered()')) { on_plot_edit() }
|
|
161
161
|
|
|
162
|
-
@plot_screenshot = Qt::Action.new(Cosmos.get_icon('screenshot.png'),
|
|
163
|
-
@plot_screenshot.statusTip =
|
|
162
|
+
@plot_screenshot = Qt::Action.new(Cosmos.get_icon('screenshot.png'), '&Screenshot Plot', self)
|
|
163
|
+
@plot_screenshot.statusTip = 'Screenshot Selected Plot'
|
|
164
164
|
@plot_screenshot.connect(SIGNAL('triggered()')) { on_plot_screenshot() }
|
|
165
165
|
|
|
166
|
-
@plot_add_data = Qt::Action.new(Cosmos.get_icon('add_database.png'),
|
|
167
|
-
@plot_add_data.statusTip =
|
|
166
|
+
@plot_add_data = Qt::Action.new(Cosmos.get_icon('add_database.png'), 'Add Data &Object', self)
|
|
167
|
+
@plot_add_data.statusTip = 'Add Data Object'
|
|
168
168
|
@plot_add_data.connect(SIGNAL('triggered()')) { on_data_object_add() }
|
|
169
169
|
|
|
170
|
-
@plot_edit_data = Qt::Action.new(Cosmos.get_icon('edit_database.png'),
|
|
171
|
-
@plot_edit_data.statusTip =
|
|
170
|
+
@plot_edit_data = Qt::Action.new(Cosmos.get_icon('edit_database.png'), 'Edit &Plot Data Objects', self)
|
|
171
|
+
@plot_edit_data.statusTip = 'Edit Plot Data Object(s)'
|
|
172
172
|
@plot_edit_data.connect(SIGNAL('triggered()')) { on_plot_data_object_edit() }
|
|
173
173
|
|
|
174
|
-
@plot_export = Qt::Action.new(
|
|
175
|
-
@plot_export.statusTip =
|
|
174
|
+
@plot_export = Qt::Action.new('E&xport Plot Data Objects', self)
|
|
175
|
+
@plot_export.statusTip = 'Export Plot Data Object(s)'
|
|
176
176
|
@plot_export.connect(SIGNAL('triggered()')) { on_plot_export() }
|
|
177
177
|
|
|
178
|
-
@plot_reset = Qt::Action.new(
|
|
179
|
-
@plot_reset.statusTip =
|
|
178
|
+
@plot_reset = Qt::Action.new('&Reset Plot Data Objects', self)
|
|
179
|
+
@plot_reset.statusTip = 'Reset Plot Data Object(s)'
|
|
180
180
|
@plot_reset.connect(SIGNAL('triggered()')) { on_plot_reset() }
|
|
181
181
|
|
|
182
182
|
# Data Object Menu
|
|
183
|
-
@data_add = Qt::Action.new(Cosmos.get_icon('add_database.png'),
|
|
184
|
-
@data_add.statusTip =
|
|
183
|
+
@data_add = Qt::Action.new(Cosmos.get_icon('add_database.png'), '&Add Data Object', self)
|
|
184
|
+
@data_add.statusTip = 'Add Data Object'
|
|
185
185
|
@data_add.connect(SIGNAL('triggered()')) { on_data_object_add() }
|
|
186
186
|
|
|
187
|
-
@data_delete = Qt::Action.new(Cosmos.get_icon('delete_database.png'),
|
|
188
|
-
@data_delete.statusTip =
|
|
187
|
+
@data_delete = Qt::Action.new(Cosmos.get_icon('delete_database.png'), '&Delete Data Object', self)
|
|
188
|
+
@data_delete.statusTip = 'Delete Selected Data Object(s)'
|
|
189
189
|
@data_delete.connect(SIGNAL('triggered()')) { on_data_object_delete() }
|
|
190
190
|
|
|
191
|
-
@data_edit = Qt::Action.new(Cosmos.get_icon('edit_database.png'),
|
|
192
|
-
@data_edit.statusTip =
|
|
191
|
+
@data_edit = Qt::Action.new(Cosmos.get_icon('edit_database.png'), '&Edit Data Object', self)
|
|
192
|
+
@data_edit.statusTip = 'Edit Selected Data Object(s)'
|
|
193
193
|
@data_edit.connect(SIGNAL('triggered()')) { on_data_object_edit() }
|
|
194
194
|
|
|
195
|
-
@data_duplicate = Qt::Action.new(
|
|
196
|
-
@data_duplicate.statusTip =
|
|
195
|
+
@data_duplicate = Qt::Action.new('Du&plicate Data Object', self)
|
|
196
|
+
@data_duplicate.statusTip = 'Duplicate Selected Data Object(s)'
|
|
197
197
|
@data_duplicate.connect(SIGNAL('triggered()')) { on_data_object_duplicate() }
|
|
198
198
|
|
|
199
|
-
@data_export = Qt::Action.new(
|
|
200
|
-
@data_export.statusTip =
|
|
199
|
+
@data_export = Qt::Action.new('E&xport Data Object', self)
|
|
200
|
+
@data_export.statusTip = 'Export Selected Data Object(s)'
|
|
201
201
|
@data_export.connect(SIGNAL('triggered()')) { on_data_object_export() }
|
|
202
202
|
|
|
203
|
-
@data_export_all = Qt::Action.new(
|
|
204
|
-
@data_export_all.statusTip =
|
|
203
|
+
@data_export_all = Qt::Action.new('Expor&t All Data Objects', self)
|
|
204
|
+
@data_export_all.statusTip = 'Export All Data Objects'
|
|
205
205
|
@data_export_all.connect(SIGNAL('triggered()')) { on_data_object_export_all() }
|
|
206
206
|
|
|
207
|
-
@data_reset = Qt::Action.new(
|
|
208
|
-
@data_reset.statusTip =
|
|
207
|
+
@data_reset = Qt::Action.new('&Reset Data Object', self)
|
|
208
|
+
@data_reset.statusTip = 'Reset Selected Data Object(s)'
|
|
209
209
|
@data_reset.connect(SIGNAL('triggered()')) { on_data_object_reset() }
|
|
210
210
|
|
|
211
|
-
@data_reset_all = Qt::Action.new(
|
|
212
|
-
@data_reset_all.statusTip =
|
|
211
|
+
@data_reset_all = Qt::Action.new('Re&set All Data Objects', self)
|
|
212
|
+
@data_reset_all.statusTip = 'Reset All Data Objects'
|
|
213
213
|
@data_reset_all.connect(SIGNAL('triggered()')) { on_data_object_reset_all() }
|
|
214
214
|
end
|
|
215
215
|
|
|
216
216
|
def initialize_menus(options)
|
|
217
217
|
# File Menu
|
|
218
|
-
@file_menu = menuBar.addMenu(
|
|
218
|
+
@file_menu = menuBar.addMenu('&File')
|
|
219
219
|
@file_menu.addAction(@file_process)
|
|
220
220
|
@file_menu.addAction(@file_dart)
|
|
221
221
|
@file_menu.addSeparator()
|
|
@@ -228,7 +228,7 @@ module Cosmos
|
|
|
228
228
|
@file_menu.addSeparator()
|
|
229
229
|
@file_menu.addAction(@exit_action)
|
|
230
230
|
|
|
231
|
-
@tab_menu = menuBar.addMenu(
|
|
231
|
+
@tab_menu = menuBar.addMenu('&Tab')
|
|
232
232
|
@tab_menu.addAction(@tab_add)
|
|
233
233
|
@tab_menu.addAction(@tab_delete)
|
|
234
234
|
@tab_menu.addAction(@tab_edit)
|
|
@@ -238,7 +238,7 @@ module Cosmos
|
|
|
238
238
|
@tab_menu.addSeparator()
|
|
239
239
|
@tab_menu.addAction(@tab_reset)
|
|
240
240
|
|
|
241
|
-
@plot_menu = menuBar.addMenu(
|
|
241
|
+
@plot_menu = menuBar.addMenu('&Plot')
|
|
242
242
|
@plot_menu.addAction(@plot_add)
|
|
243
243
|
@plot_menu.addAction(@plot_delete)
|
|
244
244
|
@plot_menu.addAction(@plot_edit)
|
|
@@ -251,7 +251,7 @@ module Cosmos
|
|
|
251
251
|
@plot_menu.addSeparator()
|
|
252
252
|
@plot_menu.addAction(@plot_reset)
|
|
253
253
|
|
|
254
|
-
@data_menu = menuBar.addMenu(
|
|
254
|
+
@data_menu = menuBar.addMenu('&Data Object')
|
|
255
255
|
@data_menu.addAction(@data_add)
|
|
256
256
|
@data_menu.addAction(@data_delete)
|
|
257
257
|
@data_menu.addAction(@data_edit)
|
|
@@ -285,7 +285,7 @@ module Cosmos
|
|
|
285
285
|
@replay_flag = Qt::Label.new("Replay Mode")
|
|
286
286
|
@replay_flag.setStyleSheet("background:green;color:white;padding:5px;font-weight:bold;height:30px;")
|
|
287
287
|
@right_frame.addWidget(@replay_flag)
|
|
288
|
-
@replay_flag.hide
|
|
288
|
+
@replay_flag.hide
|
|
289
289
|
@right_widget.setLayout(@right_frame)
|
|
290
290
|
@splitter.addWidget(@right_widget)
|
|
291
291
|
@splitter.setStretchFactor(0,0) # Set the left side stretch factor to 0
|
|
@@ -363,7 +363,7 @@ module Cosmos
|
|
|
363
363
|
|
|
364
364
|
if !File.exist?(@config_filename)
|
|
365
365
|
# Warn if the configuration file did not exist
|
|
366
|
-
statusBar.showMessage(
|
|
366
|
+
statusBar.showMessage("Configuration File does not exist: #{@config_filename}. Using default configuration.")
|
|
367
367
|
end
|
|
368
368
|
update_window_title()
|
|
369
369
|
end # def load_configuration
|
|
@@ -397,9 +397,9 @@ module Cosmos
|
|
|
397
397
|
begin
|
|
398
398
|
yield filename
|
|
399
399
|
@screenshot_dir = File.dirname(filename)
|
|
400
|
-
statusBar.showMessage(
|
|
400
|
+
statusBar.showMessage("Screenshot saved to: #{filename}")
|
|
401
401
|
rescue Exception => error
|
|
402
|
-
statusBar.showMessage(
|
|
402
|
+
statusBar.showMessage("Screenshot creation failed")
|
|
403
403
|
Qt::MessageBox.warning(
|
|
404
404
|
self,
|
|
405
405
|
"Screenshot Creation Error",
|
|
@@ -426,9 +426,9 @@ module Cosmos
|
|
|
426
426
|
dialog.complete
|
|
427
427
|
end
|
|
428
428
|
@export_dir = File.dirname(filename)
|
|
429
|
-
statusBar.showMessage(
|
|
429
|
+
statusBar.showMessage("Exported to #{filename}")
|
|
430
430
|
rescue Exception => error
|
|
431
|
-
statusBar.showMessage(
|
|
431
|
+
statusBar.showMessage("Export Failed")
|
|
432
432
|
Qt::MessageBox.warning(
|
|
433
433
|
self,
|
|
434
434
|
"Export Error",
|
|
@@ -449,9 +449,9 @@ module Cosmos
|
|
|
449
449
|
yield
|
|
450
450
|
@config_modified = true if delete
|
|
451
451
|
update_window_title() if delete
|
|
452
|
-
statusBar.showMessage(
|
|
452
|
+
statusBar.showMessage("#{action.capitalize} #{item} successful")
|
|
453
453
|
else
|
|
454
|
-
statusBar.showMessage(
|
|
454
|
+
statusBar.showMessage("#{action.capitalize} #{item} canceled")
|
|
455
455
|
end
|
|
456
456
|
end
|
|
457
457
|
def reset(item)
|
|
@@ -642,7 +642,7 @@ module Cosmos
|
|
|
642
642
|
running = @realtime_thread ? true : false
|
|
643
643
|
handle_stop()
|
|
644
644
|
System.telemetry.reset
|
|
645
|
-
@tabbed_plots.reset_all_data_objects
|
|
645
|
+
@tabbed_plots.reset_all_data_objects
|
|
646
646
|
@replay_mode = !@replay_mode
|
|
647
647
|
if @replay_mode
|
|
648
648
|
@replay_flag.show
|
|
@@ -673,7 +673,7 @@ module Cosmos
|
|
|
673
673
|
paused = @tabbed_plots.paused?
|
|
674
674
|
@tabbed_plots.pause
|
|
675
675
|
@tabbed_plots.add_tab
|
|
676
|
-
statusBar.showMessage(
|
|
676
|
+
statusBar.showMessage("Tab Added")
|
|
677
677
|
@config_modified = true
|
|
678
678
|
update_window_title()
|
|
679
679
|
@tabbed_plots.resume unless paused
|
|
@@ -693,7 +693,7 @@ module Cosmos
|
|
|
693
693
|
tab_selected? do
|
|
694
694
|
edited = @tabbed_plots.edit_tab
|
|
695
695
|
if edited
|
|
696
|
-
statusBar.showMessage(
|
|
696
|
+
statusBar.showMessage("Tab Edited")
|
|
697
697
|
@config_modified = true
|
|
698
698
|
update_window_title()
|
|
699
699
|
end
|
|
@@ -979,7 +979,7 @@ module Cosmos
|
|
|
979
979
|
if @realtime_thread
|
|
980
980
|
# Resume plotting in case it was paused
|
|
981
981
|
@tabbed_plots.resume
|
|
982
|
-
statusBar.showMessage(
|
|
982
|
+
statusBar.showMessage("Plot Updates Resumed")
|
|
983
983
|
@realtime_button_bar.state = 'Running'
|
|
984
984
|
else
|
|
985
985
|
System.load_configuration
|
|
@@ -992,7 +992,7 @@ module Cosmos
|
|
|
992
992
|
|
|
993
993
|
# Startup realtime thread
|
|
994
994
|
@realtime_button_bar.state = 'Connecting'
|
|
995
|
-
statusBar.showMessage(
|
|
995
|
+
statusBar.showMessage("Connecting to COSMOS Server")
|
|
996
996
|
@realtime_thread = TabbedPlotsRealtimeThread.new(@tabbed_plots_config, method(:realtime_thread_connection_success_callback), method(:realtime_thread_connection_failed_callback), method(:realtime_thread_connection_lost_callback), method(:realtime_thread_fatal_exception_callback), @replay_mode)
|
|
997
997
|
end
|
|
998
998
|
end # def handle_start
|
|
@@ -1002,7 +1002,7 @@ module Cosmos
|
|
|
1002
1002
|
if @realtime_thread
|
|
1003
1003
|
# Pause plotting
|
|
1004
1004
|
@tabbed_plots.pause
|
|
1005
|
-
statusBar.showMessage(
|
|
1005
|
+
statusBar.showMessage("Plot Updates Paused - Still Collecting Data in the Background")
|
|
1006
1006
|
@realtime_button_bar.state = 'Paused'
|
|
1007
1007
|
else
|
|
1008
1008
|
# Do Nothing
|
|
@@ -1017,7 +1017,7 @@ module Cosmos
|
|
|
1017
1017
|
@realtime_thread.kill
|
|
1018
1018
|
@realtime_thread = nil
|
|
1019
1019
|
@realtime_button_bar.state = 'Stopped'
|
|
1020
|
-
statusBar.showMessage(
|
|
1020
|
+
statusBar.showMessage("Disconnection from COSMOS Server Successful")
|
|
1021
1021
|
else
|
|
1022
1022
|
# Do Nothing
|
|
1023
1023
|
end
|
|
@@ -1032,7 +1032,7 @@ module Cosmos
|
|
|
1032
1032
|
def realtime_thread_connection_success_callback
|
|
1033
1033
|
# Notify user of connection success
|
|
1034
1034
|
Qt.execute_in_main_thread(true) do
|
|
1035
|
-
statusBar.showMessage(
|
|
1035
|
+
statusBar.showMessage("Connection to COSMOS Server Successful")
|
|
1036
1036
|
if @tabbed_plots.paused?
|
|
1037
1037
|
@realtime_button_bar.state = 'Paused'
|
|
1038
1038
|
else
|
|
@@ -1045,7 +1045,7 @@ module Cosmos
|
|
|
1045
1045
|
def realtime_thread_connection_failed_callback(error)
|
|
1046
1046
|
# Notify user connection failed
|
|
1047
1047
|
Qt.execute_in_main_thread(true) do
|
|
1048
|
-
statusBar.showMessage(
|
|
1048
|
+
statusBar.showMessage("Connection to COSMOS Server Failed : #{error.class} : #{error.message}")
|
|
1049
1049
|
@realtime_button_bar.state = 'Connecting'
|
|
1050
1050
|
end
|
|
1051
1051
|
end # def realtime_thread_connection_failed_callback
|
|
@@ -1055,12 +1055,12 @@ module Cosmos
|
|
|
1055
1055
|
# Notify user of connection lost
|
|
1056
1056
|
if error
|
|
1057
1057
|
Qt.execute_in_main_thread(true) do
|
|
1058
|
-
statusBar.showMessage(
|
|
1058
|
+
statusBar.showMessage("Connection to COSMOS Server Lost : #{error.class} : #{error.message}")
|
|
1059
1059
|
@realtime_button_bar.state = 'Connecting'
|
|
1060
1060
|
end
|
|
1061
1061
|
else
|
|
1062
1062
|
Qt.execute_in_main_thread(true) do
|
|
1063
|
-
statusBar.showMessage(
|
|
1063
|
+
statusBar.showMessage("Connection to COSMOS Server Lost")
|
|
1064
1064
|
@realtime_button_bar.state = 'Connecting'
|
|
1065
1065
|
end
|
|
1066
1066
|
end
|