summaryrefslogtreecommitdiff
path: root/ldmicro/includes
diff options
context:
space:
mode:
authorakshay-c2019-09-13 12:24:18 +0530
committerakshay-c2019-09-13 12:24:18 +0530
commit13b6349465e26e8cd015e4153aa8843c706275ec (patch)
tree73cd7302c00957cb6eae1cacdffb77073556beec /ldmicro/includes
parente64d76c057d561e81ad26dcc9acf04f014a855e9 (diff)
downloadLDmicroQt-13b6349465e26e8cd015e4153aa8843c706275ec.tar.gz
LDmicroQt-13b6349465e26e8cd015e4153aa8843c706275ec.tar.bz2
LDmicroQt-13b6349465e26e8cd015e4153aa8843c706275ec.zip
Patch 1 ToolBar, AnalogSlider Realtime update
Diffstat (limited to 'ldmicro/includes')
-rw-r--r--ldmicro/includes/ldmicro.h20
-rw-r--r--ldmicro/includes/ldmicroVC.h1
-rw-r--r--ldmicro/includes/toolbar.h42
3 files changed, 61 insertions, 2 deletions
diff --git a/ldmicro/includes/ldmicro.h b/ldmicro/includes/ldmicro.h
index 788c580..34b9520 100644
--- a/ldmicro/includes/ldmicro.h
+++ b/ldmicro/includes/ldmicro.h
@@ -103,6 +103,11 @@ typedef signed long SDWORD;
#define MNU_MAKE_SET_ONLY 0x44
#define MNU_MAKE_RESET_ONLY 0x45
#define MNU_INSERT_PWL 0x46
+#define MNU_INSERT_CONTACTS_N 0x47
+#define MNU_INSERT_COIL_N 0x48
+#define MNU_INSERT_COIL_S 0x49
+#define MNU_INSERT_COIL_R 0x4a
+
#define MNU_MCU_SETTINGS 0x50
#define MNU_PROCESSOR_0 0xa0
@@ -179,7 +184,9 @@ extern QAction* InsertPwlMenu;
extern QAction* McuSettingsMenu;
extern QAction* ProcessorMenuItems[NUM_SUPPORTED_MCUS+1];
-extern HMENU MicroControllerMenu;
+extern HMENU MicroControllerMenu;
+extern HMENU ArithmeticMenu;
+extern HMENU AnalogMenu;
extern QAction* SimulationModeMenu;
extern QAction* StartSimulationMenu;
@@ -489,7 +496,7 @@ typedef struct PlcProgramTag {
// offset from the top left of the window at which we start drawing, in pixels
#define X_PADDING 35
-#define Y_PADDING 14
+#define Y_PADDING 24
typedef class PlcCursorTag{
int left;
@@ -498,6 +505,8 @@ typedef class PlcCursorTag{
int height;
} PlcCursor;
+extern QToolBar* EasyAccessTool;
+
//-----------------------------------------------
// The syntax highlighting style colours; a structure for the palette.
@@ -632,6 +641,9 @@ extern int IoListTop;
extern UINT IoListHeight;
extern HMENU ScrollWindow;
+// toolbar.cpp
+void CreateToolBar(void);
+
// draw.cpp
int ProgCountWidestRow(void);
int CountHeightOfElement(int which, void *elem);
@@ -695,7 +707,11 @@ extern BOOL CanInsertComment;
// circuit.cpp
void AddTimer(int which);
void AddCoil(void);
+void AddCoilNeg(void);
+void AddCoilRes(void);
+void AddCoilSet(void);
void AddContact(void);
+void AddContactNeg(void);
void AddEmpty(int which);
void AddMove(void);
void AddMath(int which);
diff --git a/ldmicro/includes/ldmicroVC.h b/ldmicro/includes/ldmicroVC.h
index 67e0d9c..151beb9 100644
--- a/ldmicro/includes/ldmicroVC.h
+++ b/ldmicro/includes/ldmicroVC.h
@@ -1,3 +1,4 @@
/// version control
#define LDMicro_VERSION_MAJOR 2
#define LDMicro_VERSION_MINOR 2
+#define LDMicro_VERSION_PATCH 1
diff --git a/ldmicro/includes/toolbar.h b/ldmicro/includes/toolbar.h
new file mode 100644
index 0000000..2ff7397
--- /dev/null
+++ b/ldmicro/includes/toolbar.h
@@ -0,0 +1,42 @@
+#ifndef __TOOLBAR_H
+#define __TOOLBAR_H
+
+#include <QToolBar>
+#include <QIcon>
+
+extern QIcon* ContactIco;
+extern QIcon* NegContactIco;
+extern QIcon* CoilIco;
+extern QIcon* NegCoilIco;
+extern QIcon* SetCoilIco;
+extern QIcon* ResetCoilIco;
+extern QIcon* ResetTimerIco;
+extern QIcon* TonIco;
+extern QIcon* TofIco;
+extern QIcon* RtoIco;
+extern QIcon* AddIco;
+extern QIcon* SubIco;
+extern QIcon* MulIco;
+extern QIcon* DivIco;
+extern QIcon* CtuIco;
+extern QIcon* CtdIco;
+extern QAction* ContactBtn;
+extern QAction* NegContactBtn;
+extern QAction* CoilBtn;
+extern QAction* NegCoilBtn;
+extern QAction* SetCoilBtn;
+extern QAction* ResetCoilBtn;
+extern QAction* ResetTimerBtn;
+extern QAction* TonBtn;
+extern QAction* TofBtn;
+extern QAction* RtoBtn;
+extern QAction* AddBtn;
+extern QAction* SubBtn;
+extern QAction* MulBtn;
+extern QAction* DivBtn;
+extern QAction* CtuBtn;
+extern QAction* CtdBtn;
+
+// Functions
+void ToolBarHandler();
+#endif