Loading @Data/Data.m +2 −2 Original line number Diff line number Diff line Loading @@ -7,7 +7,7 @@ classdef Data < handle properties left_cond = []; top_cond = []; result_grid = []; outputs_grid = []; function_name = []; function_inputs = []; settings = []; Loading @@ -30,7 +30,7 @@ classdef Data < handle function object = Data() object.left_cond = HierarchicalGrid(); object.top_cond = HierarchicalGrid(); object.result_grid = TableGrid(); object.outputs_grid = TableGrid(); object.left_cond.addlistener('AddedOuterCell', @(src, event) left_grid_added_cell(object, src, event)) object.top_cond.addlistener('AddedOuterCell', @(src, event) top_grid_added_cell(object, src, event)) Loading @Data/init.m 0 → 100644 +11 −0 Original line number Diff line number Diff line function init( object ) %INIT Summary of this function goes here % Detailed explanation goes here object.left_cond.add_cell([], []); object.left_cond.add_cell([], []); object.top_cond.add_cell([], []); end @Data/left_grid_added_cell.m +1 −1 Original line number Diff line number Diff line function left_grid_added_cell( object, src, event ) %LEFT_GRID_ADDED_CELL Handler for when a new left condition is added. object.result_grid.add_row(event.changed_cell); object.outputs_grid.add_row(event.changed_cell); end @Data/top_grid_added_cell.m +1 −1 Original line number Diff line number Diff line function top_grid_added_cell( object, src, event ) %LEFT_GRID_ADDED_CELL Handler for when a new left condition is added. object.result_grid.add_column(event.changed_cell); object.outputs_grid.add_column(event.changed_cell); end @GUI/GUI.m +13 −5 Original line number Diff line number Diff line Loading @@ -5,12 +5,18 @@ classdef GUI < handle properties % vertical grid Grid2 = []; vertical_grid = []; % horizontal grid Grid1 = []; horizontal_grid = []; %output grid Grid0 = []; outputs_grid = []; %grid layouter grid_layout = []; %And its panel ... grid_layout_panel = []; main_fig = []; frame = []; fig = []; Loading Loading @@ -48,7 +54,7 @@ classdef GUI < handle text_width = 250; name_label = []; input_label = []; Data = []; data = []; PVS = []; CVC = []; pvs_checked = []; Loading Loading @@ -79,11 +85,13 @@ classdef GUI < handle %% GUI % constructor % inputs: % d:Data - The data to display. % h:double - handle to Tabular block in model % mode:boolean - the mode of the gui, 1 for simuink, 0 for matlab % outputs: % object:GUI - object that is created function object = GUI(h,mode) function object = GUI(data, h,mode) object.data = data; object.block_handle = h; object.mode = mode; end Loading Loading
@Data/Data.m +2 −2 Original line number Diff line number Diff line Loading @@ -7,7 +7,7 @@ classdef Data < handle properties left_cond = []; top_cond = []; result_grid = []; outputs_grid = []; function_name = []; function_inputs = []; settings = []; Loading @@ -30,7 +30,7 @@ classdef Data < handle function object = Data() object.left_cond = HierarchicalGrid(); object.top_cond = HierarchicalGrid(); object.result_grid = TableGrid(); object.outputs_grid = TableGrid(); object.left_cond.addlistener('AddedOuterCell', @(src, event) left_grid_added_cell(object, src, event)) object.top_cond.addlistener('AddedOuterCell', @(src, event) top_grid_added_cell(object, src, event)) Loading
@Data/init.m 0 → 100644 +11 −0 Original line number Diff line number Diff line function init( object ) %INIT Summary of this function goes here % Detailed explanation goes here object.left_cond.add_cell([], []); object.left_cond.add_cell([], []); object.top_cond.add_cell([], []); end
@Data/left_grid_added_cell.m +1 −1 Original line number Diff line number Diff line function left_grid_added_cell( object, src, event ) %LEFT_GRID_ADDED_CELL Handler for when a new left condition is added. object.result_grid.add_row(event.changed_cell); object.outputs_grid.add_row(event.changed_cell); end
@Data/top_grid_added_cell.m +1 −1 Original line number Diff line number Diff line function top_grid_added_cell( object, src, event ) %LEFT_GRID_ADDED_CELL Handler for when a new left condition is added. object.result_grid.add_column(event.changed_cell); object.outputs_grid.add_column(event.changed_cell); end
@GUI/GUI.m +13 −5 Original line number Diff line number Diff line Loading @@ -5,12 +5,18 @@ classdef GUI < handle properties % vertical grid Grid2 = []; vertical_grid = []; % horizontal grid Grid1 = []; horizontal_grid = []; %output grid Grid0 = []; outputs_grid = []; %grid layouter grid_layout = []; %And its panel ... grid_layout_panel = []; main_fig = []; frame = []; fig = []; Loading Loading @@ -48,7 +54,7 @@ classdef GUI < handle text_width = 250; name_label = []; input_label = []; Data = []; data = []; PVS = []; CVC = []; pvs_checked = []; Loading Loading @@ -79,11 +85,13 @@ classdef GUI < handle %% GUI % constructor % inputs: % d:Data - The data to display. % h:double - handle to Tabular block in model % mode:boolean - the mode of the gui, 1 for simuink, 0 for matlab % outputs: % object:GUI - object that is created function object = GUI(h,mode) function object = GUI(data, h,mode) object.data = data; object.block_handle = h; object.mode = mode; end Loading