VR-Forces 4.5 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
remoteControlConsole.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2012 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 /******************************************************************************
6 ** $RCSfile: remoteControlConsole.h,v $ $Revision: 1.2 $ $State: Exp $
7 ******************************************************************************/
8 //\file remoteControlConsole.h
9 
10 #pragma once
11 
12 #include <vrvUtil/signalslib.h>
13 #include <matrix/vlVector.h>
14 #include <QtWidgets/QDialog>
15 
16 namespace makVrv
17 {
18  class DtDe;
19 }
20 
21 // The DtRemoteControlConsole class will allow the user to type in remote control console commands
22 // to manipulate the simulation. For a list of commands, type "help" at the command prompt
23 
24 class QVBoxLayout;
25 class QTextEdit;
26 class QLineEdit;
28 
30 {
31  Q_OBJECT
32 
33 public:
35 
36  virtual ~DtRemoteControlConsole();
37 
38 protected:
39  virtual void addCommand(const DtRemoteControlCommand&);
40 
41  //Prints a line of text to the console window. Will add CR/LF
42  virtual void print(const QString&);
43 
44  //Prints out all help for all commands
45  virtual void help();
46 
47  //Called when a command is complete, prints out command complete string
48  virtual void slot_onCommandComplete(const QString&, DtRemoteControlCommand*);
49 
50  //Called when the user clicks on the map to set the database location. Simply adds the point to the current command line
51  virtual void slot_onDatabaseLocationSet(const DtVector&);
52 
53 protected slots:
54  //Called when return is pressed in the command widget. Processes the command
55  virtual void processCommand();
56 
57  //Parse and execute the supplied command. Command will be the first item before the
58  //space
59  virtual void executeCommand(const QString& command);
60 
61 public:
62  QVBoxLayout* myMainLayout;
63  QTextEdit* myConsole; //The output of the command
64  QLineEdit* myCommand; //Command input
65 
66 protected:
68 
69  typedef std::vector<DtRemoteControlCommand*> Commands;
70 
72 };

Document ID: Generated on Thu Mar 23 18:54:12 EDT 2017 from SVN revision 174804
Copyright © 2005-2017 VT MÄK. All Rights Reserved (www.mak.com)