Audio plugin host https://kx.studio/carla
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.

192 lines
6.4KB

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