c++ - Windows.h macros not defined -
I am creating a simple GUI library, and I've got it for the first test. The strange thing is that none of the windows macros have been defined. I am getting such errors as "Null" was not declared in Scope and "Handle" was not declared in Scope. "I'm thinking that I can be the method of organizing the code because the easywin.hpp content is not defined in the login file, but it looks like it should work. Here's the easiest (most) easywin.hpp :
#ifndef EASYWIN_BASE_HPP #define EASYWIN_BASE_HPP #include & lt; string include & gt; # & lt; map & gt; // strings are used everywhere, they std: : Can be used globally by using string; / ** * WinAPI encapsulate and Program a namespace to prevent conflicts. ** / namespace WinAPI {#include & lt; the windows.h & gt; # include & lt; includes commctrl.h & gt;} // Header (according to part order has been) #include "application.hpp" #include "object.hpp" #include "widget.hpp" #include "container. hpp" #Include "window.hpp" #include "dialogue." HPP "// Not implemented yet, so it does not include # # # "light.hpp" # Not Included "Heavy. HPP" // There are more container types # "Control .hpp" #include "textbox.hpp" #include "Tooltip.hpp" // source contains #var C #include to simplify dependency "Application.cpp" #include "Object.cpp" #include "Widget.cpp" #include "container CPP" # "Window.cpp" #include "Dialog.cpp" // now is not implemented yet, so // # "do not include Lightkcpp" # "heavily involved CPP" / X // more container type # control "control" CPP "#include" textbox.cpp "#include" tooltip .cpp "#endif I do not get this. If I am including everything in this file, those files should be defined in this file. what I have done?
EDIT: To encourage better answers, I will post the GIT repository:
This should be a comment on the answer to the Ironman because it is completely correct, but I can not fit in it ...
There are functions in the windows API In the global namespace, take the parameters of type "handle" in other words in ":: handles". To do this, windows libraries already are compiled and the compiled code exists in such libraries as a user. Lib / dll The objective type of windows.h is to define and the functions that are present in the Already library so that you can call them. That you include a unrelated WinAPI :: handle, for example, defines the types which is fine, but any such functions in the library that way does not change it's done a :: Handle is required as a parameter. I understand what you are trying to do, and this is a good motive. Although there is no way that this might possibly work.
Comments
Post a Comment