Loading...
--- Libc/Libc-1725.40.4/include/libkern/OSThermalNotification.h
+++ Libc/Libc-997.90.3/include/libkern/OSThermalNotification.h
@@ -24,12 +24,8 @@
#ifndef _OSTHERMALNOTIFICATION_H_
#define _OSTHERMALNOTIFICATION_H_
-#include <_bounds.h>
#include <sys/cdefs.h>
#include <Availability.h>
-#include <TargetConditionals.h>
-
-_LIBC_SINGLE_BY_DEFAULT()
/*
** OSThermalNotification.h
@@ -41,34 +37,6 @@
*/
__BEGIN_DECLS
-
-/* Define pressure levels usable by OSThermalPressureLevel */
-typedef enum {
-#if TARGET_OS_OSX || TARGET_OS_MACCATALYST
- kOSThermalPressureLevelNominal = 0,
- kOSThermalPressureLevelModerate,
- kOSThermalPressureLevelHeavy,
- kOSThermalPressureLevelTrapping,
- kOSThermalPressureLevelSleeping
-#else
- kOSThermalPressureLevelNominal = 0,
- kOSThermalPressureLevelLight = 10,
- kOSThermalPressureLevelModerate = 20,
- kOSThermalPressureLevelHeavy = 30,
- kOSThermalPressureLevelTrapping = 40,
- kOSThermalPressureLevelSleeping = 50
-#endif
-} OSThermalPressureLevel;
-
-/*
- ** External notify(3) string for thermal pressure level notification
- */
-__OSX_AVAILABLE_STARTING(__MAC_10_10, __IPHONE_7_0)
-extern const char * const kOSThermalNotificationPressureLevelName;
-
-
-#if defined(__IPHONE_OS_VERSION_MIN_REQUIRED) && \
- __IPHONE_OS_VERSION_MIN_REQUIRED >= __IPHONE_2_0
typedef enum {
OSThermalNotificationLevelAny = -1,
@@ -108,31 +76,45 @@
#define OSThermalNotificationLevelUrgent OSThermalNotificationLevelAppTerminate
#define OSThermalNotificationLevelCritical OSThermalNotificationLevelDeviceRestart
+/* Define pressure levels usable by OSThermalPressureLevel */
+typedef enum {
+ kOSThermalPressureLevelNominal = 0,
+ kOSThermalPressureLevelModerate,
+ kOSThermalPressureLevelHeavy,
+ kOSThermalPressureLevelTrapping,
+ kOSThermalPressureLevelSleeping
+} OSThermalPressureLevel;
+
/*
** Simple polling interface to detect current thermal level
*/
-__OSX_AVAILABLE_STARTING(__MAC_NA, __IPHONE_2_0)
-extern OSThermalNotificationLevel OSThermalNotificationCurrentLevel(void);
+
+extern OSThermalNotificationLevel OSThermalNotificationCurrentLevel(void) __OSX_AVAILABLE_STARTING(__MAC_NA, __IPHONE_2_0);
/*
** External notify(3) string for manual notification setup
*/
-__OSX_AVAILABLE_STARTING(__MAC_NA, __IPHONE_2_0)
-extern const char * const kOSThermalNotificationName;
+
+extern const char * const kOSThermalNotificationName __OSX_AVAILABLE_STARTING(__MAC_NA, __IPHONE_2_0);
/*
** External notify(3) string for alerting user of a thermal condition
*/
-__OSX_AVAILABLE_STARTING(__MAC_NA, __IPHONE_6_0)
-extern const char * const kOSThermalNotificationAlert;
+
+extern const char * const kOSThermalNotificationAlert __OSX_AVAILABLE_STARTING(__MAC_NA, __IPHONE_6_0);
/*
** External notify(3) string for notifying system the options taken to resolve thermal condition
*/
-__OSX_AVAILABLE_STARTING(__MAC_NA, __IPHONE_6_0)
-extern const char * const kOSThermalNotificationDecision;
-#endif // __IPHONE_OS_VERSION_MIN_REQUIRED
+extern const char * const kOSThermalNotificationDecision __OSX_AVAILABLE_STARTING(__MAC_NA, __IPHONE_6_0);
+
+/*
+** External notify(3) string for thermal pressure level notification
+*/
+
+extern const char * const kOSThermalNotificationPressureLevelName __OSX_AVAILABLE_STARTING(__MAC_NA, __IPHONE_7_0);
+
__END_DECLS