@@ -81,19 +81,19 @@ public: | |||||
auto leftSlice = bounds.removeFromLeft (150); | auto leftSlice = bounds.removeFromLeft (150); | ||||
auto centreSlice = bounds; | auto centreSlice = bounds; | ||||
//====================================================================== | |||||
//============================================================================== | |||||
rightSlice.removeFromRight (20); | rightSlice.removeFromRight (20); | ||||
auto iconSlice = rightSlice.removeFromRight (100); | auto iconSlice = rightSlice.removeFromRight (100); | ||||
huckleberryLogoBounds = iconSlice.removeFromBottom (100).toFloat(); | huckleberryLogoBounds = iconSlice.removeFromBottom (100).toFloat(); | ||||
//====================================================================== | |||||
//============================================================================== | |||||
juceLogoBounds = leftSlice.removeFromTop (150).toFloat(); | juceLogoBounds = leftSlice.removeFromTop (150).toFloat(); | ||||
juceLogoBounds.setWidth (juceLogoBounds.getWidth() + 100); | juceLogoBounds.setWidth (juceLogoBounds.getWidth() + 100); | ||||
juceLogoBounds.setHeight (juceLogoBounds.getHeight() + 100); | juceLogoBounds.setHeight (juceLogoBounds.getHeight() + 100); | ||||
copyrightLabel.setBounds (leftSlice.removeFromBottom (20)); | copyrightLabel.setBounds (leftSlice.removeFromBottom (20)); | ||||
//====================================================================== | |||||
//============================================================================== | |||||
auto titleHeight = 40; | auto titleHeight = 40; | ||||
centreSlice.removeFromTop ((centreSlice.getHeight() / 2) - (titleHeight / 2)); | centreSlice.removeFromTop ((centreSlice.getHeight() / 2) - (titleHeight / 2)); | ||||
@@ -510,7 +510,7 @@ void ProjucerApplication::createColourSchemeItems (PopupMenu& menu) | |||||
menu.addSubMenu ("Colour Scheme", colourSchemeMenu); | menu.addSubMenu ("Colour Scheme", colourSchemeMenu); | ||||
//========================================================================== | |||||
//============================================================================== | |||||
PopupMenu editorColourSchemeMenu; | PopupMenu editorColourSchemeMenu; | ||||
auto& appearanceSettings = getAppSettings().appearance; | auto& appearanceSettings = getAppSettings().appearance; | ||||
@@ -625,7 +625,7 @@ void ProjucerApplication::createExamplesPopupMenu (PopupMenu& menu) noexcept | |||||
} | } | ||||
} | } | ||||
//========================================================================== | |||||
//============================================================================== | |||||
static File getJUCEExamplesDirectoryPathFromGlobal() | static File getJUCEExamplesDirectoryPathFromGlobal() | ||||
{ | { | ||||
auto globalPath = File::createFileWithoutCheckingPath (getAppSettings().getStoredPath (Ids::jucePath, TargetOS::getThisOS()).get().toString() | auto globalPath = File::createFileWithoutCheckingPath (getAppSettings().getStoredPath (Ids::jucePath, TargetOS::getThisOS()).get().toString() | ||||
@@ -722,7 +722,7 @@ void ProjucerApplication::findAndLaunchExample (int selectedIndex) | |||||
Analytics::getInstance()->logEvent ("Example Opened", data, ProjucerAnalyticsEvent::exampleEvent); | Analytics::getInstance()->logEvent ("Example Opened", data, ProjucerAnalyticsEvent::exampleEvent); | ||||
} | } | ||||
//========================================================================== | |||||
//============================================================================== | |||||
static String getPlatformSpecificFileExtension() | static String getPlatformSpecificFileExtension() | ||||
{ | { | ||||
#if JUCE_MAC | #if JUCE_MAC | ||||
@@ -940,7 +940,7 @@ void ProjucerApplication::launchDemoRunner() | |||||
} | } | ||||
} | } | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void ProjucerApplication::handleMainMenuCommand (int menuItemID) | void ProjucerApplication::handleMainMenuCommand (int menuItemID) | ||||
{ | { | ||||
if (menuItemID >= recentProjectsBaseID && menuItemID < (recentProjectsBaseID + 100)) | if (menuItemID >= recentProjectsBaseID && menuItemID < (recentProjectsBaseID + 100)) | ||||
@@ -368,7 +368,7 @@ private: | |||||
Project& project; | Project& project; | ||||
ValueTree exportersTree; | ValueTree exportersTree; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void valueTreeChildAdded (ValueTree& parentTree, ValueTree&) override { refreshIfNeeded (parentTree); } | void valueTreeChildAdded (ValueTree& parentTree, ValueTree&) override { refreshIfNeeded (parentTree); } | ||||
void valueTreeChildRemoved (ValueTree& parentTree, ValueTree&, int) override { refreshIfNeeded (parentTree); } | void valueTreeChildRemoved (ValueTree& parentTree, ValueTree&, int) override { refreshIfNeeded (parentTree); } | ||||
void valueTreeChildOrderChanged (ValueTree& parentTree, int, int) override { refreshIfNeeded (parentTree); } | void valueTreeChildOrderChanged (ValueTree& parentTree, int, int) override { refreshIfNeeded (parentTree); } | ||||
@@ -172,7 +172,7 @@ private: | |||||
Rectangle<int> textBounds; | Rectangle<int> textBounds; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
String getErrorMessage() | String getErrorMessage() | ||||
{ | { | ||||
showDownloadButton = false; | showDownloadButton = false; | ||||
@@ -27,7 +27,7 @@ | |||||
#pragma once | #pragma once | ||||
//========================================================================== | |||||
//============================================================================== | |||||
struct ProjectSettingsComponent : public Component, | struct ProjectSettingsComponent : public Component, | ||||
private ChangeListener | private ChangeListener | ||||
{ | { | ||||
@@ -35,7 +35,7 @@ | |||||
#include "../../LiveBuildEngine/jucer_DiagnosticMessage.h" | #include "../../LiveBuildEngine/jucer_DiagnosticMessage.h" | ||||
#include "../../LiveBuildEngine/jucer_CompileEngineClient.h" | #include "../../LiveBuildEngine/jucer_CompileEngineClient.h" | ||||
//====================================================================== | |||||
//============================================================================== | |||||
HeaderComponent::HeaderComponent() | HeaderComponent::HeaderComponent() | ||||
{ | { | ||||
addAndMakeVisible (configLabel); | addAndMakeVisible (configLabel); | ||||
@@ -66,13 +66,13 @@ HeaderComponent::~HeaderComponent() | |||||
} | } | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
void HeaderComponent::resized() | void HeaderComponent::resized() | ||||
{ | { | ||||
auto bounds = getLocalBounds(); | auto bounds = getLocalBounds(); | ||||
configLabel.setFont ({ bounds.getHeight() / 3.0f }); | configLabel.setFont ({ bounds.getHeight() / 3.0f }); | ||||
//====================================================================== | |||||
//============================================================================== | |||||
{ | { | ||||
auto headerBounds = bounds.removeFromLeft (tabsWidth); | auto headerBounds = bounds.removeFromLeft (tabsWidth); | ||||
@@ -87,7 +87,7 @@ void HeaderComponent::resized() | |||||
projectNameLabel.setBounds (headerBounds); | projectNameLabel.setBounds (headerBounds); | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
auto exporterWidth = jmin (400, bounds.getWidth() / 2); | auto exporterWidth = jmin (400, bounds.getWidth() / 2); | ||||
Rectangle<int> exporterBounds (0, 0, exporterWidth, bounds.getHeight()); | Rectangle<int> exporterBounds (0, 0, exporterWidth, bounds.getHeight()); | ||||
@@ -114,7 +114,7 @@ void HeaderComponent::paint (Graphics& g) | |||||
runAppButton->getWidth(), runAppButton->getHeight()); | runAppButton->getWidth(), runAppButton->getHeight()); | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
void HeaderComponent::setCurrentProject (Project* p) noexcept | void HeaderComponent::setCurrentProject (Project* p) noexcept | ||||
{ | { | ||||
project = p; | project = p; | ||||
@@ -148,7 +148,7 @@ void HeaderComponent::setCurrentProject (Project* p) noexcept | |||||
} | } | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
void HeaderComponent::updateExporters() noexcept | void HeaderComponent::updateExporters() noexcept | ||||
{ | { | ||||
auto selectedName = getSelectedExporterName(); | auto selectedName = getSelectedExporterName(); | ||||
@@ -203,7 +203,7 @@ bool HeaderComponent::canCurrentExporterLaunchProject() const noexcept | |||||
return false; | return false; | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
int HeaderComponent::getUserButtonWidth() const noexcept | int HeaderComponent::getUserButtonWidth() const noexcept | ||||
{ | { | ||||
return userSettingsButton->getWidth(); | return userSettingsButton->getWidth(); | ||||
@@ -215,7 +215,7 @@ void HeaderComponent::sidebarTabsWidthChanged (int newWidth) noexcept | |||||
resized(); | resized(); | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
void HeaderComponent::showUserSettings() noexcept | void HeaderComponent::showUserSettings() noexcept | ||||
{ | { | ||||
#if JUCER_ENABLE_GPL_MODE | #if JUCER_ENABLE_GPL_MODE | ||||
@@ -233,7 +233,7 @@ void HeaderComponent::showUserSettings() noexcept | |||||
userSettingsWindow = &CallOutBox::launchAsynchronously (content, userSettingsButton->getScreenBounds(), nullptr); | userSettingsWindow = &CallOutBox::launchAsynchronously (content, userSettingsButton->getScreenBounds(), nullptr); | ||||
} | } | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void HeaderComponent::lookAndFeelChanged() | void HeaderComponent::lookAndFeelChanged() | ||||
{ | { | ||||
if (userSettingsWindow != nullptr) | if (userSettingsWindow != nullptr) | ||||
@@ -261,7 +261,7 @@ void HeaderComponent::timerCallback() | |||||
repaint(); | repaint(); | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
static void sendProjectButtonAnalyticsEvent (StringRef label) | static void sendProjectButtonAnalyticsEvent (StringRef label) | ||||
{ | { | ||||
StringPairArray data; | StringPairArray data; | ||||
@@ -351,7 +351,7 @@ void HeaderComponent::updateUserAvatar() noexcept | |||||
} | } | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
void HeaderComponent::buildPing() | void HeaderComponent::buildPing() | ||||
{ | { | ||||
if (! isTimerRunning()) | if (! isTimerRunning()) | ||||
@@ -43,33 +43,33 @@ public: | |||||
HeaderComponent(); | HeaderComponent(); | ||||
~HeaderComponent() override; | ~HeaderComponent() override; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void resized() override; | void resized() override; | ||||
void paint (Graphics&) override; | void paint (Graphics&) override; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void setCurrentProject (Project*) noexcept; | void setCurrentProject (Project*) noexcept; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void updateExporters() noexcept; | void updateExporters() noexcept; | ||||
String getSelectedExporterName() const noexcept; | String getSelectedExporterName() const noexcept; | ||||
bool canCurrentExporterLaunchProject() const noexcept; | bool canCurrentExporterLaunchProject() const noexcept; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
int getUserButtonWidth() const noexcept; | int getUserButtonWidth() const noexcept; | ||||
void sidebarTabsWidthChanged (int newWidth) noexcept; | void sidebarTabsWidthChanged (int newWidth) noexcept; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void showUserSettings() noexcept; | void showUserSettings() noexcept; | ||||
private: | private: | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void lookAndFeelChanged() override; | void lookAndFeelChanged() override; | ||||
void changeListenerCallback (ChangeBroadcaster* source) override; | void changeListenerCallback (ChangeBroadcaster* source) override; | ||||
void valueChanged (Value&) override; | void valueChanged (Value&) override; | ||||
void timerCallback() override; | void timerCallback() override; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void valueTreeChildAdded (ValueTree& parentTree, ValueTree&) override { updateIfNeeded (parentTree); } | void valueTreeChildAdded (ValueTree& parentTree, ValueTree&) override { updateIfNeeded (parentTree); } | ||||
void valueTreeChildRemoved (ValueTree& parentTree, ValueTree&, int) override { updateIfNeeded (parentTree); } | void valueTreeChildRemoved (ValueTree& parentTree, ValueTree&, int) override { updateIfNeeded (parentTree); } | ||||
void valueTreeChildOrderChanged (ValueTree& parentTree, int, int) override { updateIfNeeded (parentTree); } | void valueTreeChildOrderChanged (ValueTree& parentTree, int, int) override { updateIfNeeded (parentTree); } | ||||
@@ -80,19 +80,19 @@ private: | |||||
updateExporters(); | updateExporters(); | ||||
} | } | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void initialiseButtons() noexcept; | void initialiseButtons() noexcept; | ||||
void updateName() noexcept; | void updateName() noexcept; | ||||
void updateExporterButton() noexcept; | void updateExporterButton() noexcept; | ||||
void updateUserAvatar() noexcept; | void updateUserAvatar() noexcept; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void buildPing(); | void buildPing(); | ||||
void buildFinished (bool); | void buildFinished (bool); | ||||
void setRunAppButtonState (bool); | void setRunAppButtonState (bool); | ||||
//========================================================================== | |||||
//============================================================================== | |||||
int tabsWidth = 200; | int tabsWidth = 200; | ||||
bool isBuilding = false; | bool isBuilding = false; | ||||
@@ -122,24 +122,24 @@ public: | |||||
bounds.removeFromLeft (5); | bounds.removeFromLeft (5); | ||||
g.setColour (rowIsSelected ? findColour (defaultHighlightedTextColourId) : findColour (widgetTextColourId)); | g.setColour (rowIsSelected ? findColour (defaultHighlightedTextColourId) : findColour (widgetTextColourId)); | ||||
//====================================================================== | |||||
//============================================================================== | |||||
auto moduleID = project.getEnabledModules().getModuleID (rowNumber); | auto moduleID = project.getEnabledModules().getModuleID (rowNumber); | ||||
g.drawFittedText (moduleID, bounds.removeFromLeft (roundToInt (listHeader->getProportionAtIndex (0) * width)), Justification::centredLeft, 1); | g.drawFittedText (moduleID, bounds.removeFromLeft (roundToInt (listHeader->getProportionAtIndex (0) * width)), Justification::centredLeft, 1); | ||||
//====================================================================== | |||||
//============================================================================== | |||||
auto version = project.getEnabledModules().getModuleInfo (moduleID).getVersion(); | auto version = project.getEnabledModules().getModuleInfo (moduleID).getVersion(); | ||||
if (version.isEmpty()) | if (version.isEmpty()) | ||||
version = "?"; | version = "?"; | ||||
g.drawFittedText (version, bounds.removeFromLeft (roundToInt (listHeader->getProportionAtIndex (1) * width)), Justification::centredLeft, 1); | g.drawFittedText (version, bounds.removeFromLeft (roundToInt (listHeader->getProportionAtIndex (1) * width)), Justification::centredLeft, 1); | ||||
//====================================================================== | |||||
//============================================================================== | |||||
auto copyLocally = project.getEnabledModules().shouldCopyModuleFilesLocally (moduleID).getValue() ? "Yes" : "No"; | auto copyLocally = project.getEnabledModules().shouldCopyModuleFilesLocally (moduleID).getValue() ? "Yes" : "No"; | ||||
g.drawFittedText (copyLocally, bounds.removeFromLeft (roundToInt (listHeader->getProportionAtIndex (2) * width)), Justification::centredLeft, 1); | g.drawFittedText (copyLocally, bounds.removeFromLeft (roundToInt (listHeader->getProportionAtIndex (2) * width)), Justification::centredLeft, 1); | ||||
//====================================================================== | |||||
//============================================================================== | |||||
String pathText; | String pathText; | ||||
if (project.getEnabledModules().shouldUseGlobalPath (moduleID)) | if (project.getEnabledModules().shouldUseGlobalPath (moduleID)) | ||||
@@ -255,7 +255,7 @@ void ProjectContentComponent::rebuildProjectTabs() | |||||
addAndMakeVisible (sidebarTabs); | addAndMakeVisible (sidebarTabs); | ||||
createProjectTabs(); | createProjectTabs(); | ||||
//====================================================================== | |||||
//============================================================================== | |||||
auto& settings = project->getStoredProperties(); | auto& settings = project->getStoredProperties(); | ||||
auto lastTreeWidth = settings.getValue ("projectPanelWidth").getIntValue(); | auto lastTreeWidth = settings.getValue ("projectPanelWidth").getIntValue(); | ||||
@@ -271,7 +271,7 @@ void ProjectContentComponent::rebuildProjectTabs() | |||||
projectTab->setPanelHeightProportion (i, settings.getValue ("projectTabPanelHeight" + String (i), "1") | projectTab->setPanelHeightProportion (i, settings.getValue ("projectTabPanelHeight" + String (i), "1") | ||||
.getFloatValue()); | .getFloatValue()); | ||||
//====================================================================== | |||||
//============================================================================== | |||||
resizerBar.reset (new ResizableEdgeComponent (&sidebarTabs, &sidebarSizeConstrainer, | resizerBar.reset (new ResizableEdgeComponent (&sidebarTabs, &sidebarSizeConstrainer, | ||||
ResizableEdgeComponent::rightEdge)); | ResizableEdgeComponent::rightEdge)); | ||||
addAndMakeVisible (resizerBar.get()); | addAndMakeVisible (resizerBar.get()); | ||||
@@ -627,7 +627,7 @@ protected: | |||||
optimisationLevelValue.setDefault (isDebug() ? gccO0 : gccO3); | optimisationLevelValue.setDefault (isDebug() ? gccO0 : gccO3); | ||||
} | } | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void createConfigProperties (PropertyListBuilder& props) override | void createConfigProperties (PropertyListBuilder& props) override | ||||
{ | { | ||||
addXcodePluginInstallPathProperties (props); | addXcodePluginInstallPathProperties (props); | ||||
@@ -684,7 +684,7 @@ protected: | |||||
return "${CURRENT_ARCH}"; | return "${CURRENT_ARCH}"; | ||||
} | } | ||||
//========================================================================== | |||||
//============================================================================== | |||||
String getOSXArchitectureString() const { return osxArchitecture.get(); } | String getOSXArchitectureString() const { return osxArchitecture.get(); } | ||||
String getPListPreprocessorDefinitionsString() const { return plistPreprocessorDefinitions.get(); } | String getPListPreprocessorDefinitionsString() const { return plistPreprocessorDefinitions.get(); } | ||||
@@ -711,7 +711,7 @@ protected: | |||||
String getUnityPluginBinaryLocationString() const { return unityPluginBinaryLocation.get(); } | String getUnityPluginBinaryLocationString() const { return unityPluginBinaryLocation.get(); } | ||||
private: | private: | ||||
//========================================================================== | |||||
//============================================================================== | |||||
bool iOS; | bool iOS; | ||||
ValueWithDefault osxSDKVersion, osxDeploymentTarget, iosDeploymentTarget, osxArchitecture, | ValueWithDefault osxSDKVersion, osxDeploymentTarget, iosDeploymentTarget, osxArchitecture, | ||||
@@ -720,7 +720,7 @@ protected: | |||||
vstBinaryLocation, vst3BinaryLocation, auBinaryLocation, rtasBinaryLocation, | vstBinaryLocation, vst3BinaryLocation, auBinaryLocation, rtasBinaryLocation, | ||||
aaxBinaryLocation, unityPluginBinaryLocation; | aaxBinaryLocation, unityPluginBinaryLocation; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void addXcodePluginInstallPathProperties (PropertyListBuilder& props) | void addXcodePluginInstallPathProperties (PropertyListBuilder& props) | ||||
{ | { | ||||
auto isBuildingAnyPlugins = (project.shouldBuildVST() || project.shouldBuildVST3() || project.shouldBuildAU() | auto isBuildingAnyPlugins = (project.shouldBuildVST() || project.shouldBuildVST3() || project.shouldBuildAU() | ||||
@@ -1434,7 +1434,7 @@ public: | |||||
} | } | ||||
private: | private: | ||||
//============================================================================= | |||||
//============================================================================== | |||||
void* (*threadEntryProc) (void*) = nullptr; | void* (*threadEntryProc) (void*) = nullptr; | ||||
void* threadUserPtr = nullptr; | void* threadUserPtr = nullptr; | ||||
@@ -1351,13 +1351,13 @@ public: | |||||
} | } | ||||
private: | private: | ||||
//============================================================================= | |||||
//============================================================================== | |||||
static void staticFinished (SLAndroidSimpleBufferQueueItf, void* context) | static void staticFinished (SLAndroidSimpleBufferQueueItf, void* context) | ||||
{ | { | ||||
static_cast<SLRealtimeThread*> (context)->finished(); | static_cast<SLRealtimeThread*> (context)->finished(); | ||||
} | } | ||||
//============================================================================= | |||||
//============================================================================== | |||||
DynamicLibrary slLibrary { "libOpenSLES.so" }; | DynamicLibrary slLibrary { "libOpenSLES.so" }; | ||||
SlRef<SLEngineItf_> engine; | SlRef<SLEngineItf_> engine; | ||||
@@ -125,7 +125,7 @@ public: | |||||
AudioDeviceManager& deviceManager; | AudioDeviceManager& deviceManager; | ||||
private: | private: | ||||
//============================================================================= | |||||
//============================================================================== | |||||
AudioDeviceManager defaultDeviceManager; | AudioDeviceManager defaultDeviceManager; | ||||
AudioSourcePlayer audioSourcePlayer; | AudioSourcePlayer audioSourcePlayer; | ||||
bool usingCustomDeviceManager; | bool usingCustomDeviceManager; | ||||
@@ -137,7 +137,7 @@ public: | |||||
void clear() noexcept { touches.clear(); } | void clear() noexcept { touches.clear(); } | ||||
private: | private: | ||||
//========================================================================== | |||||
//============================================================================== | |||||
static bool matches (const TouchSurface::Touch& t1, | static bool matches (const TouchSurface::Touch& t1, | ||||
const TouchSurface::Touch& t2) noexcept | const TouchSurface::Touch& t2) noexcept | ||||
{ | { | ||||
@@ -54,7 +54,7 @@ public: | |||||
/** This method will tell, if an other PhysicalTopologySource has locked the Midi connection */ | /** This method will tell, if an other PhysicalTopologySource has locked the Midi connection */ | ||||
bool isLockedFromOutside() const; | bool isLockedFromOutside() const; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
/** For custom transport systems, this represents a connected device */ | /** For custom transport systems, this represents a connected device */ | ||||
struct DeviceConnection | struct DeviceConnection | ||||
{ | { | ||||
@@ -86,7 +86,7 @@ protected: | |||||
virtual void handleTimerTick(); | virtual void handleTimerTick(); | ||||
private: | private: | ||||
//========================================================================== | |||||
//============================================================================== | |||||
DeviceDetector* customDetector = nullptr; | DeviceDetector* customDetector = nullptr; | ||||
friend struct Detector; | friend struct Detector; | ||||
struct DetectorHolder; | struct DetectorHolder; | ||||
@@ -43,7 +43,7 @@ public: | |||||
/** Destructor. */ | /** Destructor. */ | ||||
~RuleBasedTopologySource() override; | ~RuleBasedTopologySource() override; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
/** Returns the currently active topology. */ | /** Returns the currently active topology. */ | ||||
BlockTopology getCurrentTopology() const override; | BlockTopology getCurrentTopology() const override; | ||||
@@ -80,7 +80,7 @@ public: | |||||
bool isActive() const override; | bool isActive() const override; | ||||
private: | private: | ||||
//========================================================================== | |||||
//============================================================================== | |||||
struct Internal; | struct Internal; | ||||
std::unique_ptr<Internal> internal; | std::unique_ptr<Internal> internal; | ||||
}; | }; | ||||
@@ -30,7 +30,7 @@ namespace juce | |||||
class TopologySource | class TopologySource | ||||
{ | { | ||||
public: | public: | ||||
//========================================================================== | |||||
//============================================================================== | |||||
/** Destructor. */ | /** Destructor. */ | ||||
virtual ~TopologySource() = default; | virtual ~TopologySource() = default; | ||||
@@ -43,7 +43,7 @@ public: | |||||
/** Returns true, if the TopologySource is currently trying to connect the block devices */ | /** Returns true, if the TopologySource is currently trying to connect the block devices */ | ||||
virtual bool isActive() const = 0; | virtual bool isActive() const = 0; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
/** Used to receive callbacks for topology changes */ | /** Used to receive callbacks for topology changes */ | ||||
struct Listener | struct Listener | ||||
{ | { | ||||
@@ -71,7 +71,7 @@ public: | |||||
virtual void cancelAllActiveTouches() noexcept {} | virtual void cancelAllActiveTouches() noexcept {} | ||||
protected: | protected: | ||||
//========================================================================== | |||||
//============================================================================== | |||||
ListenerList<Listener> listeners; | ListenerList<Listener> listeners; | ||||
}; | }; | ||||
@@ -38,7 +38,7 @@ struct Oversampling<SampleType>::OversamplingStage | |||||
OversamplingStage (size_t numChans, size_t newFactor) : numChannels (numChans), factor (newFactor) {} | OversamplingStage (size_t numChans, size_t newFactor) : numChannels (numChans), factor (newFactor) {} | ||||
virtual ~OversamplingStage() {} | virtual ~OversamplingStage() {} | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
virtual SampleType getLatencyInSamples() = 0; | virtual SampleType getLatencyInSamples() = 0; | ||||
virtual void initProcessing (size_t maximumNumberOfSamplesBeforeOversampling) | virtual void initProcessing (size_t maximumNumberOfSamplesBeforeOversampling) | ||||
@@ -66,7 +66,7 @@ struct Oversampling<SampleType>::OversamplingStage | |||||
}; | }; | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
/** Dummy oversampling stage class which simply copies and pastes the input | /** Dummy oversampling stage class which simply copies and pastes the input | ||||
signal, which could be equivalent to a "one time" oversampling processing. | signal, which could be equivalent to a "one time" oversampling processing. | ||||
*/ | */ | ||||
@@ -77,7 +77,7 @@ struct OversamplingDummy : public Oversampling<SampleType>::OversamplingStage | |||||
OversamplingDummy (size_t numChans) : ParentType (numChans, 1) {} | OversamplingDummy (size_t numChans) : ParentType (numChans, 1) {} | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
SampleType getLatencyInSamples() override | SampleType getLatencyInSamples() override | ||||
{ | { | ||||
return 0; | return 0; | ||||
@@ -104,7 +104,7 @@ struct OversamplingDummy : public Oversampling<SampleType>::OversamplingStage | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (OversamplingDummy) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (OversamplingDummy) | ||||
}; | }; | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
/** Oversampling stage class performing 2 times oversampling using the Filter | /** Oversampling stage class performing 2 times oversampling using the Filter | ||||
Design FIR Equiripple method. The resulting filter is linear phase, | Design FIR Equiripple method. The resulting filter is linear phase, | ||||
symmetric, and has every two samples but the middle one equal to zero, | symmetric, and has every two samples but the middle one equal to zero, | ||||
@@ -138,7 +138,7 @@ struct Oversampling2TimesEquirippleFIR : public Oversampling<SampleType>::Overs | |||||
position.resize (static_cast<int> (this->numChannels)); | position.resize (static_cast<int> (this->numChannels)); | ||||
} | } | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
SampleType getLatencyInSamples() override | SampleType getLatencyInSamples() override | ||||
{ | { | ||||
return static_cast<SampleType> (coefficientsUp.getFilterOrder() + coefficientsDown.getFilterOrder()) * 0.5f; | return static_cast<SampleType> (coefficientsUp.getFilterOrder() + coefficientsDown.getFilterOrder()) * 0.5f; | ||||
@@ -247,17 +247,17 @@ struct Oversampling2TimesEquirippleFIR : public Oversampling<SampleType>::Overs | |||||
} | } | ||||
private: | private: | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
dsp::FIR::Coefficients<SampleType> coefficientsUp, coefficientsDown; | dsp::FIR::Coefficients<SampleType> coefficientsUp, coefficientsDown; | ||||
AudioBuffer<SampleType> stateUp, stateDown, stateDown2; | AudioBuffer<SampleType> stateUp, stateDown, stateDown2; | ||||
Array<size_t> position; | Array<size_t> position; | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (Oversampling2TimesEquirippleFIR) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (Oversampling2TimesEquirippleFIR) | ||||
}; | }; | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
/** Oversampling stage class performing 2 times oversampling using the Filter | /** Oversampling stage class performing 2 times oversampling using the Filter | ||||
Design IIR Polyphase Allpass Cascaded method. The resulting filter is minimum | Design IIR Polyphase Allpass Cascaded method. The resulting filter is minimum | ||||
phase, and provided with a method to get the exact resulting latency. | phase, and provided with a method to get the exact resulting latency. | ||||
@@ -299,7 +299,7 @@ struct Oversampling2TimesPolyphaseIIR : public Oversampling<SampleType>::Oversa | |||||
delayDown.resize (static_cast<int> (this->numChannels)); | delayDown.resize (static_cast<int> (this->numChannels)); | ||||
} | } | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
SampleType getLatencyInSamples() override | SampleType getLatencyInSamples() override | ||||
{ | { | ||||
return latency; | return latency; | ||||
@@ -453,7 +453,7 @@ struct Oversampling2TimesPolyphaseIIR : public Oversampling<SampleType>::Oversa | |||||
} | } | ||||
private: | private: | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
/** This function calculates the equivalent high order IIR filter of a given | /** This function calculates the equivalent high order IIR filter of a given | ||||
polyphase cascaded allpass filters structure. | polyphase cascaded allpass filters structure. | ||||
*/ | */ | ||||
@@ -515,19 +515,19 @@ private: | |||||
return coeffs; | return coeffs; | ||||
} | } | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
Array<SampleType> coefficientsUp, coefficientsDown; | Array<SampleType> coefficientsUp, coefficientsDown; | ||||
SampleType latency; | SampleType latency; | ||||
AudioBuffer<SampleType> v1Up, v1Down; | AudioBuffer<SampleType> v1Up, v1Down; | ||||
Array<SampleType> delayDown; | Array<SampleType> delayDown; | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (Oversampling2TimesPolyphaseIIR) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (Oversampling2TimesPolyphaseIIR) | ||||
}; | }; | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
template <typename SampleType> | template <typename SampleType> | ||||
Oversampling<SampleType>::Oversampling (size_t newNumChannels) | Oversampling<SampleType>::Oversampling (size_t newNumChannels) | ||||
: numChannels (newNumChannels) | : numChannels (newNumChannels) | ||||
@@ -590,7 +590,7 @@ Oversampling<SampleType>::~Oversampling() | |||||
stages.clear(); | stages.clear(); | ||||
} | } | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
template <typename SampleType> | template <typename SampleType> | ||||
void Oversampling<SampleType>::addDummyOversamplingStage() | void Oversampling<SampleType>::addDummyOversamplingStage() | ||||
{ | { | ||||
@@ -627,7 +627,7 @@ void Oversampling<SampleType>::clearOversamplingStages() | |||||
factorOversampling = 1u; | factorOversampling = 1u; | ||||
} | } | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
template <typename SampleType> | template <typename SampleType> | ||||
SampleType Oversampling<SampleType>::getLatencyInSamples() noexcept | SampleType Oversampling<SampleType>::getLatencyInSamples() noexcept | ||||
{ | { | ||||
@@ -649,7 +649,7 @@ size_t Oversampling<SampleType>::getOversamplingFactor() noexcept | |||||
return factorOversampling; | return factorOversampling; | ||||
} | } | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
template <typename SampleType> | template <typename SampleType> | ||||
void Oversampling<SampleType>::initProcessing (size_t maximumNumberOfSamplesBeforeOversampling) | void Oversampling<SampleType>::initProcessing (size_t maximumNumberOfSamplesBeforeOversampling) | ||||
{ | { | ||||
@@ -29,7 +29,7 @@ namespace juce | |||||
namespace dsp | namespace dsp | ||||
{ | { | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
/** | /** | ||||
A processing class performing multi-channel oversampling. | A processing class performing multi-channel oversampling. | ||||
@@ -65,7 +65,7 @@ public: | |||||
numFilterTypes | numFilterTypes | ||||
}; | }; | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
/** | /** | ||||
Constructor of the oversampling class. All the processing parameters must be | Constructor of the oversampling class. All the processing parameters must be | ||||
provided at the creation of the oversampling object. | provided at the creation of the oversampling object. | ||||
@@ -96,7 +96,7 @@ public: | |||||
/** Destructor. */ | /** Destructor. */ | ||||
~Oversampling(); | ~Oversampling(); | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
/** Returns the latency in samples of the whole processing. Use this information | /** Returns the latency in samples of the whole processing. Use this information | ||||
in your main processor to compensate the additional latency involved with | in your main processor to compensate the additional latency involved with | ||||
the oversampling, for example with a dry / wet functionality, and to report | the oversampling, for example with a dry / wet functionality, and to report | ||||
@@ -110,7 +110,7 @@ public: | |||||
/** Returns the current oversampling factor. */ | /** Returns the current oversampling factor. */ | ||||
size_t getOversamplingFactor() noexcept; | size_t getOversamplingFactor() noexcept; | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
/** Must be called before any processing, to set the buffer sizes of the internal | /** Must be called before any processing, to set the buffer sizes of the internal | ||||
buffers of the oversampling processing. | buffers of the oversampling processing. | ||||
*/ | */ | ||||
@@ -135,7 +135,7 @@ public: | |||||
*/ | */ | ||||
void processSamplesDown (dsp::AudioBlock<SampleType>& outputBlock) noexcept; | void processSamplesDown (dsp::AudioBlock<SampleType>& outputBlock) noexcept; | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
/** Adds a new oversampling stage to the Oversampling class, multiplying the | /** Adds a new oversampling stage to the Oversampling class, multiplying the | ||||
current oversampling factor by two. This is used with the default constructor | current oversampling factor by two. This is used with the default constructor | ||||
to create custom oversampling chains, requiring a call to the | to create custom oversampling chains, requiring a call to the | ||||
@@ -179,7 +179,7 @@ public: | |||||
*/ | */ | ||||
void clearOversamplingStages(); | void clearOversamplingStages(); | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
size_t factorOversampling = 1; | size_t factorOversampling = 1; | ||||
size_t numChannels = 1; | size_t numChannels = 1; | ||||
@@ -188,11 +188,11 @@ public: | |||||
#endif | #endif | ||||
private: | private: | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
OwnedArray<OversamplingStage> stages; | OwnedArray<OversamplingStage> stages; | ||||
bool isReady = false; | bool isReady = false; | ||||
//=============================================================================== | |||||
//============================================================================== | |||||
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (Oversampling) | JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (Oversampling) | ||||
}; | }; | ||||
@@ -219,7 +219,7 @@ void SidePanel::mouseUp (const MouseEvent&) | |||||
} | } | ||||
} | } | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void SidePanel::lookAndFeelChanged() | void SidePanel::lookAndFeelChanged() | ||||
{ | { | ||||
auto& lf = getLookAndFeel(); | auto& lf = getLookAndFeel(); | ||||
@@ -193,7 +193,7 @@ public: | |||||
std::function<void(bool)> onPanelShowHide; | std::function<void(bool)> onPanelShowHide; | ||||
private: | private: | ||||
//========================================================================== | |||||
//============================================================================== | |||||
Component* parent = nullptr; | Component* parent = nullptr; | ||||
OptionalScopedPointer<Component> contentComponent; | OptionalScopedPointer<Component> contentComponent; | ||||
OptionalScopedPointer<Component> titleBarComponent; | OptionalScopedPointer<Component> titleBarComponent; | ||||
@@ -216,7 +216,7 @@ private: | |||||
bool shouldShowDismissButton = true; | bool shouldShowDismissButton = true; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void lookAndFeelChanged() override; | void lookAndFeelChanged() override; | ||||
void componentMovedOrResized (Component&, bool wasMoved, bool wasResized) override; | void componentMovedOrResized (Component&, bool wasMoved, bool wasResized) override; | ||||
@@ -50,7 +50,7 @@ public: | |||||
JUCE_DECLARE_SINGLETON (PushNotifications, false) | JUCE_DECLARE_SINGLETON (PushNotifications, false) | ||||
#endif | #endif | ||||
//========================================================================== | |||||
//============================================================================== | |||||
/** Represents a notification that can be sent or received. */ | /** Represents a notification that can be sent or received. */ | ||||
struct Notification | struct Notification | ||||
{ | { | ||||
@@ -107,7 +107,7 @@ public: | |||||
/**@}*/ | /**@}*/ | ||||
}; | }; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
/** @name Common fields */ | /** @name Common fields */ | ||||
/**@{*/ | /**@{*/ | ||||
@@ -149,7 +149,7 @@ public: | |||||
/**@}*/ | /**@}*/ | ||||
//========================================================================== | |||||
//============================================================================== | |||||
/** @name iOS only fields */ | /** @name iOS only fields */ | ||||
/**@{*/ | /**@{*/ | ||||
@@ -161,7 +161,7 @@ public: | |||||
/**@}*/ | /**@}*/ | ||||
//========================================================================== | |||||
//============================================================================== | |||||
/** @name Android only fields */ | /** @name Android only fields */ | ||||
/**@{*/ | /**@{*/ | ||||
@@ -323,7 +323,7 @@ public: | |||||
}; | }; | ||||
//========================================================================== | |||||
//============================================================================== | |||||
/** Describes settings we want to use for current device. Note that at the | /** Describes settings we want to use for current device. Note that at the | ||||
moment this is only used on iOS and partially on OSX. | moment this is only used on iOS and partially on OSX. | ||||
@@ -438,7 +438,7 @@ public: | |||||
*/ | */ | ||||
void requestSettingsUsed(); | void requestSettingsUsed(); | ||||
//========================================================================== | |||||
//============================================================================== | |||||
/** Android API level 26 or higher only: Represents notification channel through which | /** Android API level 26 or higher only: Represents notification channel through which | ||||
notifications will be sent. Starting from Android API level 26, you should call setupChannels() | notifications will be sent. Starting from Android API level 26, you should call setupChannels() | ||||
at the start of your application, before posting any notifications. Then, when sending notifications, | at the start of your application, before posting any notifications. Then, when sending notifications, | ||||
@@ -491,7 +491,7 @@ public: | |||||
*/ | */ | ||||
void setupChannels (const Array<ChannelGroup>& groups, const Array<Channel>& channels); | void setupChannels (const Array<ChannelGroup>& groups, const Array<Channel>& channels); | ||||
//========================================================================== | |||||
//============================================================================== | |||||
/** iOS only: sends an asynchronous request to retrieve a list of notifications that were | /** iOS only: sends an asynchronous request to retrieve a list of notifications that were | ||||
scheduled and not yet delivered. | scheduled and not yet delivered. | ||||
@@ -505,7 +505,7 @@ public: | |||||
/** Unschedules all pending local notifications. iOS only. */ | /** Unschedules all pending local notifications. iOS only. */ | ||||
void removeAllPendingLocalNotifications(); | void removeAllPendingLocalNotifications(); | ||||
//========================================================================== | |||||
//============================================================================== | |||||
/** Checks whether notifications are enabled for given application. | /** Checks whether notifications are enabled for given application. | ||||
On iOS and OSX this will always return true, use requestSettingsUsed() instead. | On iOS and OSX this will always return true, use requestSettingsUsed() instead. | ||||
*/ | */ | ||||
@@ -535,7 +535,7 @@ public: | |||||
/** Removes all notifications that were delivered. */ | /** Removes all notifications that were delivered. */ | ||||
void removeAllDeliveredNotifications(); | void removeAllDeliveredNotifications(); | ||||
//========================================================================== | |||||
//============================================================================== | |||||
/** Retrieves current device token. Note, it is not a good idea to cache this token | /** Retrieves current device token. Note, it is not a good idea to cache this token | ||||
because it may change in the meantime. Always call this method to get the current | because it may change in the meantime. Always call this method to get the current | ||||
token value. | token value. | ||||
@@ -587,7 +587,7 @@ public: | |||||
int timeToLive, | int timeToLive, | ||||
const StringPairArray& additionalData); | const StringPairArray& additionalData); | ||||
//========================================================================== | |||||
//============================================================================== | |||||
/** Register a listener (ideally on application startup) to receive information about | /** Register a listener (ideally on application startup) to receive information about | ||||
notifications received and any callbacks to async functions called. | notifications received and any callbacks to async functions called. | ||||
*/ | */ | ||||
@@ -189,7 +189,7 @@ DECLARE_JNI_CLASS_WITH_MIN_SDK (RemoteInputBuilder, "android/app/RemoteInput$Bui | |||||
DECLARE_JNI_CLASS_WITH_MIN_SDK (StatusBarNotification, "android/service/notification/StatusBarNotification", 23) | DECLARE_JNI_CLASS_WITH_MIN_SDK (StatusBarNotification, "android/service/notification/StatusBarNotification", 23) | ||||
#undef JNI_CLASS_MEMBERS | #undef JNI_CLASS_MEMBERS | ||||
//========================================================================== | |||||
//============================================================================== | |||||
#if defined(JUCE_FIREBASE_INSTANCE_ID_SERVICE_CLASSNAME) | #if defined(JUCE_FIREBASE_INSTANCE_ID_SERVICE_CLASSNAME) | ||||
#define JNI_CLASS_MEMBERS(METHOD, STATICMETHOD, FIELD, STATICFIELD, CALLBACK) \ | #define JNI_CLASS_MEMBERS(METHOD, STATICMETHOD, FIELD, STATICFIELD, CALLBACK) \ | ||||
STATICMETHOD (getInstance, "getInstance", "()Lcom/google/firebase/iid/FirebaseInstanceId;") \ | STATICMETHOD (getInstance, "getInstance", "()Lcom/google/firebase/iid/FirebaseInstanceId;") \ | ||||
@@ -265,7 +265,7 @@ bool PushNotifications::Notification::isValid() const noexcept | |||||
return isValidForPreApi26; | return isValidForPreApi26; | ||||
} | } | ||||
//========================================================================== | |||||
//============================================================================== | |||||
struct PushNotifications::Pimpl | struct PushNotifications::Pimpl | ||||
{ | { | ||||
Pimpl (PushNotifications& p) | Pimpl (PushNotifications& p) | ||||
@@ -287,7 +287,7 @@ struct PushNotifications::Pimpl | |||||
return true; | return true; | ||||
} | } | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void sendLocalNotification (const PushNotifications::Notification& n) | void sendLocalNotification (const PushNotifications::Notification& n) | ||||
{ | { | ||||
// All required fields have to be setup! | // All required fields have to be setup! | ||||
@@ -434,7 +434,7 @@ struct PushNotifications::Pimpl | |||||
} | } | ||||
} | } | ||||
//========================================================================== | |||||
//============================================================================== | |||||
String getDeviceToken() const | String getDeviceToken() const | ||||
{ | { | ||||
#if defined(JUCE_FIREBASE_INSTANCE_ID_SERVICE_CLASSNAME) | #if defined(JUCE_FIREBASE_INSTANCE_ID_SERVICE_CLASSNAME) | ||||
@@ -460,7 +460,7 @@ struct PushNotifications::Pimpl | |||||
#endif | #endif | ||||
} | } | ||||
//========================================================================== | |||||
//============================================================================== | |||||
void subscribeToTopic (const String& topic) | void subscribeToTopic (const String& topic) | ||||
{ | { | ||||
#if defined(JUCE_FIREBASE_MESSAGING_SERVICE_CLASSNAME) | #if defined(JUCE_FIREBASE_MESSAGING_SERVICE_CLASSNAME) | ||||
@@ -57,7 +57,7 @@ | |||||
//============================================================================== | //============================================================================== | ||||
#include <juce_gui_extra/juce_gui_extra.h> | #include <juce_gui_extra/juce_gui_extra.h> | ||||
//============================================================================= | |||||
//============================================================================== | |||||
/** Config: JUCE_USE_CAMERA | /** Config: JUCE_USE_CAMERA | ||||
Enables camera support using the CameraDevice class (Mac, Windows, iOS, Android). | Enables camera support using the CameraDevice class (Mac, Windows, iOS, Android). | ||||
*/ | */ | ||||
@@ -79,7 +79,7 @@ | |||||
#undef JUCE_USE_CAMERA | #undef JUCE_USE_CAMERA | ||||
#endif | #endif | ||||
//============================================================================= | |||||
//============================================================================== | |||||
/** Config: JUCE_SYNC_VIDEO_VOLUME_WITH_OS_MEDIA_VOLUME | /** Config: JUCE_SYNC_VIDEO_VOLUME_WITH_OS_MEDIA_VOLUME | ||||
Enables synchronisation between video playback volume and OS media volume. | Enables synchronisation between video playback volume and OS media volume. | ||||
Currently supported on Android only. | Currently supported on Android only. | ||||
@@ -98,6 +98,6 @@ | |||||
#define JUCE_VIDEO_LOG(x) {} | #define JUCE_VIDEO_LOG(x) {} | ||||
#endif | #endif | ||||
//============================================================================= | |||||
//============================================================================== | |||||
#include "playback/juce_VideoComponent.h" | #include "playback/juce_VideoComponent.h" | ||||
#include "capture/juce_CameraDevice.h" | #include "capture/juce_CameraDevice.h" |
@@ -1032,7 +1032,7 @@ private: | |||||
} | } | ||||
private: | private: | ||||
//============================================================================= | |||||
//============================================================================== | |||||
struct StateInfo | struct StateInfo | ||||
{ | { | ||||
int playbackStateFlag = 0, allowedActions = 0; | int playbackStateFlag = 0, allowedActions = 0; | ||||
@@ -26,7 +26,7 @@ | |||||
namespace VideoRenderers | namespace VideoRenderers | ||||
{ | { | ||||
//====================================================================== | |||||
//============================================================================== | |||||
struct Base | struct Base | ||||
{ | { | ||||
virtual ~Base() {} | virtual ~Base() {} | ||||
@@ -39,7 +39,7 @@ namespace VideoRenderers | |||||
virtual HRESULT getVideoSize (long& videoWidth, long& videoHeight) = 0; | virtual HRESULT getVideoSize (long& videoWidth, long& videoHeight) = 0; | ||||
}; | }; | ||||
//====================================================================== | |||||
//============================================================================== | |||||
struct VMR7 : public Base | struct VMR7 : public Base | ||||
{ | { | ||||
VMR7() {} | VMR7() {} | ||||
@@ -99,7 +99,7 @@ namespace VideoRenderers | |||||
}; | }; | ||||
//====================================================================== | |||||
//============================================================================== | |||||
struct EVR : public Base | struct EVR : public Base | ||||
{ | { | ||||
EVR() {} | EVR() {} | ||||
@@ -390,7 +390,7 @@ private: | |||||
std::unique_ptr<ComponentWatcher> componentWatcher; | std::unique_ptr<ComponentWatcher> componentWatcher; | ||||
//====================================================================== | |||||
//============================================================================== | |||||
struct DirectShowContext : public AsyncUpdater | struct DirectShowContext : public AsyncUpdater | ||||
{ | { | ||||
DirectShowContext (Pimpl& c) : component (c) | DirectShowContext (Pimpl& c) : component (c) | ||||
@@ -404,7 +404,7 @@ private: | |||||
CoUninitialize(); | CoUninitialize(); | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
void updateWindowPosition (const Rectangle<int>& newBounds) | void updateWindowPosition (const Rectangle<int>& newBounds) | ||||
{ | { | ||||
nativeWindow->setWindowPosition (newBounds); | nativeWindow->setWindowPosition (newBounds); | ||||
@@ -415,7 +415,7 @@ private: | |||||
nativeWindow->showWindow (shouldBeVisible); | nativeWindow->showWindow (shouldBeVisible); | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
void repaint() | void repaint() | ||||
{ | { | ||||
if (hasVideo) | if (hasVideo) | ||||
@@ -434,7 +434,7 @@ private: | |||||
videoRenderer->displayModeChanged(); | videoRenderer->displayModeChanged(); | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
void peerChanged() | void peerChanged() | ||||
{ | { | ||||
deleteNativeWindow(); | deleteNativeWindow(); | ||||
@@ -489,7 +489,7 @@ private: | |||||
triggerAsyncUpdate(); | triggerAsyncUpdate(); | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
Result loadFile (const String& fileOrURLPath) | Result loadFile (const String& fileOrURLPath) | ||||
{ | { | ||||
jassert (state == uninitializedState); | jassert (state == uninitializedState); | ||||
@@ -668,7 +668,7 @@ private: | |||||
} | } | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
void play() | void play() | ||||
{ | { | ||||
mediaControl->Run(); | mediaControl->Run(); | ||||
@@ -687,7 +687,7 @@ private: | |||||
state = pausedState; | state = pausedState; | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
Rectangle<int> getVideoSize() const noexcept | Rectangle<int> getVideoSize() const noexcept | ||||
{ | { | ||||
long width = 0, height = 0; | long width = 0, height = 0; | ||||
@@ -698,7 +698,7 @@ private: | |||||
return { (int) width, (int) height }; | return { (int) width, (int) height }; | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
double getDuration() const | double getDuration() const | ||||
{ | { | ||||
REFTIME duration; | REFTIME duration; | ||||
@@ -744,7 +744,7 @@ private: | |||||
State state = uninitializedState; | State state = uninitializedState; | ||||
private: | private: | ||||
//====================================================================== | |||||
//============================================================================== | |||||
enum { graphEventID = WM_APP + 0x43f0 }; | enum { graphEventID = WM_APP + 0x43f0 }; | ||||
Pimpl& component; | Pimpl& component; | ||||
@@ -762,7 +762,7 @@ private: | |||||
bool hasVideo = false, needToUpdateViewport = true, needToRecreateNativeWindow = false; | bool hasVideo = false, needToUpdateViewport = true, needToRecreateNativeWindow = false; | ||||
//====================================================================== | |||||
//============================================================================== | |||||
bool createNativeWindow() | bool createNativeWindow() | ||||
{ | { | ||||
jassert (nativeWindow == nullptr); | jassert (nativeWindow == nullptr); | ||||
@@ -839,7 +839,7 @@ private: | |||||
return false; | return false; | ||||
} | } | ||||
//====================================================================== | |||||
//============================================================================== | |||||
struct NativeWindowClass : private DeletedAtShutdown | struct NativeWindowClass : private DeletedAtShutdown | ||||
{ | { | ||||
bool isRegistered() const noexcept { return atom != 0; } | bool isRegistered() const noexcept { return atom != 0; } | ||||
@@ -899,7 +899,7 @@ private: | |||||
JUCE_DECLARE_NON_COPYABLE (NativeWindowClass) | JUCE_DECLARE_NON_COPYABLE (NativeWindowClass) | ||||
}; | }; | ||||
//====================================================================== | |||||
//============================================================================== | |||||
struct NativeWindow | struct NativeWindow | ||||
{ | { | ||||
NativeWindow (HWND parentToAddTo, void* userData) | NativeWindow (HWND parentToAddTo, void* userData) | ||||