File tree Expand file tree Collapse file tree 7 files changed +24
-9
lines changed
Dataflow/Engine/Controller Expand file tree Collapse file tree 7 files changed +24
-9
lines changed Original file line number Diff line number Diff line change @@ -88,6 +88,7 @@ namespace SCIRun
8888 ImportNetworkFile,
8989 RunPythonScript,
9090 SetupDataDirectory,
91+ DisableViewScenes,
9192 ExecuteCurrentNetwork,
9293 InteractiveMode,
9394 SetupQuitAfterExecute,
Original file line number Diff line number Diff line change @@ -68,6 +68,8 @@ CommandHandle ConsoleGlobalCommandFactory::create(GlobalCommands type) const
6868 return boost::make_shared<QuitAfterExecuteCommandConsole>();
6969 case GlobalCommands::QuitCommand:
7070 return boost::make_shared<QuitCommandConsole>();
71+ case GlobalCommands::DisableViewScenes:
72+ return boost::make_shared<NothingCommand>();
7173 default :
7274 THROW_INVALID_ARGUMENT (" Unknown global command type." );
7375 }
Original file line number Diff line number Diff line change @@ -41,17 +41,14 @@ namespace Console {
4141 public:
4242 LoadFileCommandConsole ();
4343 virtual bool execute () override ;
44- private:
45- int index_ = 0 ;
44+ // private:
45+ // int index_ = 0;
4646 };
4747
4848 class SCISHARE SaveFileCommandConsole : public Core::Commands::ConsoleCommand
4949 {
5050 public:
51- // LoadFileCommandConsole();
5251 virtual bool execute () override ;
53- // private:
54- // int index_ = 0;
5552 };
5653
5754 class SCISHARE RunPythonScriptCommandConsole : public Core::Commands::ConsoleCommand
Original file line number Diff line number Diff line change @@ -612,7 +612,8 @@ boost::shared_ptr<PyModule> PythonImpl::findModule(const std::string& id) const
612612
613613std::string PythonImpl::executeAll (const ExecutableLookup* lookup)
614614{
615- // TODO: if contains view scene, need to disable all connections to it.
615+ cmdFactory_->create (GlobalCommands::DisableViewScenes)->execute ();
616+
616617 nec_.executeAll (lookup);
617618 return " Execution started." ; // TODO: attach log for execution ended event.
618619}
Original file line number Diff line number Diff line change @@ -62,6 +62,8 @@ CommandHandle GuiGlobalCommandFactory::create(GlobalCommands type) const
6262 return boost::make_shared<SetupDataDirectoryCommandGui>();
6363 case GlobalCommands::ExecuteCurrentNetwork:
6464 return boost::make_shared<ExecuteCurrentNetworkCommandGui>();
65+ case GlobalCommands::DisableViewScenes:
66+ return boost::make_shared<DisableViewScenesCommandGui>();
6567 case GlobalCommands::InteractiveMode:
6668 return boost::make_shared<InteractiveModeCommandConsole>();
6769 case GlobalCommands::SetupQuitAfterExecute:
Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ bool LoadFileCommandGui::execute()
6565 auto inputFilesFromCommandLine = Application::Instance ().parameters ()->inputFiles ();
6666
6767 if (!inputFilesFromCommandLine.empty ())
68- inputFile = inputFilesFromCommandLine[index_ ];
68+ inputFile = inputFilesFromCommandLine[0 ];
6969 else
7070 {
7171 inputFile = get (Variables::Filename).toFilename ().string ();
@@ -317,3 +317,9 @@ NetworkFileProcessCommand::NetworkFileProcessCommand() : networkEditor_(SCIRunMa
317317{
318318 addParameter (Variables::Filename, std::string ());
319319}
320+
321+ bool DisableViewScenesCommandGui::execute ()
322+ {
323+ qDebug () << " todo: DisableViewScenes" ;
324+ return true ;
325+ }
Original file line number Diff line number Diff line change @@ -47,8 +47,8 @@ namespace Gui {
4747 public:
4848 LoadFileCommandGui ();
4949 virtual bool execute () override ;
50- private:
51- int index_ = 0 ;
50+ // private:
51+ // int index_ = 0;
5252 };
5353
5454 class RunPythonScriptCommandGui : public Core ::Commands::GuiCommand
@@ -134,6 +134,12 @@ namespace Gui {
134134 NetworkSaveCommand ();
135135 virtual bool execute () override ;
136136 };
137+
138+ class DisableViewScenesCommandGui : public Core ::Commands::GuiCommand
139+ {
140+ public:
141+ virtual bool execute () override ;
142+ };
137143}
138144}
139145#endif
You can’t perform that action at this time.
0 commit comments