system_version.h 593 B

12345678910111213141516171819202122232425262728293031323334353637
  1. #ifndef UTILS_WINVERSION
  2. #define UTILS_WINVERSION
  3. #include <stdint.h>
  4. #include <string>
  5. namespace am {
  6. typedef struct _winversion_info
  7. {
  8. int major;
  9. int minor;
  10. int build;
  11. int revis;
  12. } winversion_info;
  13. class system_version
  14. {
  15. private:
  16. system_version();
  17. public:
  18. static bool get_dll(const std::string tar, winversion_info *info);
  19. static void get_win(winversion_info *info);
  20. static bool is_win8_or_above();
  21. static bool is_win10_or_above(int build_number = -1);
  22. static bool is_32();
  23. private:
  24. std::string _target_file;
  25. };
  26. } // namespace am
  27. #endif