https://git.reactos.org/?p=reactos.git;a=commitdiff;h=ec1b499aac8e4db642add…
commit ec1b499aac8e4db642add9fa46d55a5903077cab
Author: Carlo-Bramini <carlo_bramini(a)users.sourceforge.net>
AuthorDate: Mon Aug 6 19:58:23 2018 +0200
Commit: Hermès Bélusca-Maïto <hermes.belusca-maito(a)reactos.org>
CommitDate: Mon Mar 18 01:34:01 2019 +0100
[CALC] Improve headers inclusion.
---
base/applications/calc/calc.h | 20 ++++++++++++++------
base/applications/calc/winmain.c | 26 ++++++++++++++++++++------
2 files changed, 34 insertions(+), 12 deletions(-)
diff --git a/base/applications/calc/calc.h b/base/applications/calc/calc.h
index 702ad47e77..afbc813d83 100644
--- a/base/applications/calc/calc.h
+++ b/base/applications/calc/calc.h
@@ -1,10 +1,14 @@
-#ifndef _CALC_H
-#define _CALC_H
+#ifndef __CALC_H__
+#define __CALC_H__
-#include <stdarg.h>
-#include <windef.h>
-#include <winuser.h>
+#define WIN32_LEAN_AND_MEAN
+#include <windows.h>
#include <tchar.h>
+#include <commctrl.h>
+#include <shellapi.h>
+
+#include <stdio.h>
+#include <string.h>
#include <math.h>
#include <float.h>
#include <malloc.h>
@@ -43,6 +47,8 @@
#define IDC_STATIC ((DWORD)-1)
#endif
+#define CALC_VERSION _T("1.12")
+
#define MAX_CALC_SIZE 256
/*#define USE_KEYBOARD_HOOK*/
@@ -226,8 +232,10 @@ void convert_real_integer(unsigned int base);
INT_PTR CALLBACK AboutDlgProc(HWND hWnd, UINT msg, WPARAM wp, LPARAM lp);
+//
+
void ConvExecute(HWND hWnd);
void ConvAdjust(HWND hWnd, int n_cat);
void ConvInit(HWND hWnd);
-#endif /* _CALC_H */
+#endif /* __CALC_H__ */
diff --git a/base/applications/calc/winmain.c b/base/applications/calc/winmain.c
index c6723bac18..ad9b5763b4 100644
--- a/base/applications/calc/winmain.c
+++ b/base/applications/calc/winmain.c
@@ -1,10 +1,24 @@
-#include "calc.h"
+/*
+ * ReactOS Calc (main program)
+ *
+ * Copyright 2007-2017, Carlo Bramini
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
-#include <winbase.h>
-#include <wingdi.h>
-#include <winreg.h>
-#include <shellapi.h>
-#include <commctrl.h>
+#include "calc.h"
#define HTMLHELP_PATH(_pt) TEXT("%systemroot%\\Help\\calc.chm::") TEXT(_pt)