The JUCE cross-platform C++ framework, with DISTRHO/KXStudio specific changes
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

193 lines
6.2KB

  1. /*
  2. ==============================================================================
  3. This file is part of the JUCE library.
  4. Copyright (c) 2020 - Raw Material Software Limited
  5. JUCE is an open source library subject to commercial or open-source
  6. licensing.
  7. By using JUCE, you agree to the terms of both the JUCE 6 End-User License
  8. Agreement and JUCE Privacy Policy (both effective as of the 16th June 2020).
  9. End User License Agreement: www.juce.com/juce-6-licence
  10. Privacy Policy: www.juce.com/juce-privacy-policy
  11. Or: You may also use this code under the terms of the GPL v3 (see
  12. www.gnu.org/licenses).
  13. JUCE IS PROVIDED "AS IS" WITHOUT ANY WARRANTY, AND ALL WARRANTIES, WHETHER
  14. EXPRESSED OR IMPLIED, INCLUDING MERCHANTABILITY AND FITNESS FOR PURPOSE, ARE
  15. DISCLAIMED.
  16. ==============================================================================
  17. */
  18. #ifdef JUCE_GUI_EXTRA_H_INCLUDED
  19. /* When you add this cpp file to your project, you mustn't include it in a file where you've
  20. already included any other headers - just put it inside a file on its own, possibly with your config
  21. flags preceding it, but don't include anything else. That also includes avoiding any automatic prefix
  22. header files that the compiler may be using.
  23. */
  24. #error "Incorrect use of JUCE cpp file"
  25. #endif
  26. #define JUCE_CORE_INCLUDE_OBJC_HELPERS 1
  27. #define JUCE_CORE_INCLUDE_COM_SMART_PTR 1
  28. #define JUCE_CORE_INCLUDE_JNI_HELPERS 1
  29. #define JUCE_CORE_INCLUDE_NATIVE_HEADERS 1
  30. #define JUCE_EVENTS_INCLUDE_WIN32_MESSAGE_WINDOW 1
  31. #define JUCE_GRAPHICS_INCLUDE_COREGRAPHICS_HELPERS 1
  32. #define JUCE_GUI_BASICS_INCLUDE_XHEADERS 1
  33. #ifndef JUCE_PUSH_NOTIFICATIONS
  34. #define JUCE_PUSH_NOTIFICATIONS 0
  35. #endif
  36. #include "juce_gui_extra.h"
  37. //==============================================================================
  38. #if JUCE_MAC
  39. #import <WebKit/WebKit.h>
  40. #import <IOKit/IOKitLib.h>
  41. #import <IOKit/IOCFPlugIn.h>
  42. #import <IOKit/hid/IOHIDLib.h>
  43. #import <IOKit/hid/IOHIDKeys.h>
  44. #import <IOKit/pwr_mgt/IOPMLib.h>
  45. #if JUCE_PUSH_NOTIFICATIONS
  46. #import <Foundation/NSUserNotification.h>
  47. #include "native/juce_mac_PushNotifications.cpp"
  48. #endif
  49. //==============================================================================
  50. #elif JUCE_IOS
  51. #import <WebKit/WebKit.h>
  52. #if JUCE_PUSH_NOTIFICATIONS
  53. #if defined (__IPHONE_10_0) && __IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_10_0
  54. #import <UserNotifications/UserNotifications.h>
  55. #endif
  56. #include "native/juce_ios_PushNotifications.cpp"
  57. #endif
  58. //==============================================================================
  59. #elif JUCE_ANDROID
  60. #if JUCE_PUSH_NOTIFICATIONS
  61. #include "native/juce_android_PushNotifications.cpp"
  62. #endif
  63. //==============================================================================
  64. #elif JUCE_WINDOWS
  65. #include <windowsx.h>
  66. #include <vfw.h>
  67. #include <commdlg.h>
  68. #if JUCE_WEB_BROWSER
  69. #include <exdisp.h>
  70. #include <exdispid.h>
  71. #if JUCE_USE_WIN_WEBVIEW2
  72. #include <windows.foundation.h>
  73. #include <windows.foundation.collections.h>
  74. #pragma warning (push)
  75. #pragma warning (disable: 4265)
  76. #include <wrl.h>
  77. #include <wrl/wrappers/corewrappers.h>
  78. #pragma warning (pop)
  79. #include "WebView2.h"
  80. #pragma warning (push)
  81. #pragma warning (disable: 4458)
  82. #include "WebView2EnvironmentOptions.h"
  83. #pragma warning (pop)
  84. #endif
  85. #endif
  86. //==============================================================================
  87. #elif JUCE_LINUX && JUCE_WEB_BROWSER
  88. JUCE_BEGIN_IGNORE_WARNINGS_GCC_LIKE ("-Wzero-as-null-pointer-constant", "-Wparentheses")
  89. // If you're missing this header, you need to install the webkit2gtk-4.0 package
  90. #include <gtk/gtk.h>
  91. JUCE_END_IGNORE_WARNINGS_GCC_LIKE
  92. // If you're missing these headers, you need to install the webkit2gtk-4.0 package
  93. #include <gtk/gtkx.h>
  94. #include <glib-unix.h>
  95. #include <webkit2/webkit2.h>
  96. #endif
  97. //==============================================================================
  98. #include "documents/juce_FileBasedDocument.cpp"
  99. #include "code_editor/juce_CodeDocument.cpp"
  100. #include "code_editor/juce_CodeEditorComponent.cpp"
  101. #include "code_editor/juce_CPlusPlusCodeTokeniser.cpp"
  102. #include "code_editor/juce_XMLCodeTokeniser.cpp"
  103. #include "code_editor/juce_LuaCodeTokeniser.cpp"
  104. #include "misc/juce_BubbleMessageComponent.cpp"
  105. #include "misc/juce_ColourSelector.cpp"
  106. #include "misc/juce_KeyMappingEditorComponent.cpp"
  107. #include "misc/juce_PreferencesPanel.cpp"
  108. #include "misc/juce_PushNotifications.cpp"
  109. #include "misc/juce_RecentlyOpenedFilesList.cpp"
  110. #include "misc/juce_SplashScreen.cpp"
  111. #include "misc/juce_SystemTrayIconComponent.cpp"
  112. #include "misc/juce_LiveConstantEditor.cpp"
  113. #include "misc/juce_AnimatedAppComponent.cpp"
  114. //==============================================================================
  115. #if JUCE_MAC || JUCE_IOS
  116. #if JUCE_MAC
  117. #include "native/juce_mac_NSViewComponent.mm"
  118. #include "native/juce_mac_AppleRemote.mm"
  119. #include "native/juce_mac_SystemTrayIcon.cpp"
  120. #endif
  121. #if JUCE_IOS
  122. #include "native/juce_ios_UIViewComponent.mm"
  123. #endif
  124. #if JUCE_WEB_BROWSER
  125. #include "native/juce_mac_WebBrowserComponent.mm"
  126. #endif
  127. //==============================================================================
  128. #elif JUCE_WINDOWS
  129. #include "native/juce_win32_ActiveXComponent.cpp"
  130. #include "native/juce_win32_HWNDComponent.cpp"
  131. #if JUCE_WEB_BROWSER
  132. #include "native/juce_win32_WebBrowserComponent.cpp"
  133. #endif
  134. #include "native/juce_win32_SystemTrayIcon.cpp"
  135. //==============================================================================
  136. #elif JUCE_LINUX
  137. JUCE_BEGIN_IGNORE_WARNINGS_GCC_LIKE ("-Wzero-as-null-pointer-constant")
  138. #include "native/juce_linux_XEmbedComponent.cpp"
  139. #if JUCE_WEB_BROWSER
  140. #include "native/juce_linux_X11_WebBrowserComponent.cpp"
  141. #endif
  142. JUCE_END_IGNORE_WARNINGS_GCC_LIKE
  143. #include "native/juce_linux_X11_SystemTrayIcon.cpp"
  144. //==============================================================================
  145. #elif JUCE_ANDROID
  146. #include "native/juce_AndroidViewComponent.cpp"
  147. #if JUCE_WEB_BROWSER
  148. #include "native/juce_android_WebBrowserComponent.cpp"
  149. #endif
  150. #endif