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.

57 lines
1.9KB

  1. #pragma once
  2. %%include_juce%%
  3. //==============================================================================
  4. /*
  5. This component lives inside our window, and this is where you should put all
  6. your controls and content.
  7. */
  8. class %%content_component_class%% : public juce::AnimatedAppComponent
  9. {
  10. public:
  11. //==============================================================================
  12. %%content_component_class%%()
  13. {
  14. // Make sure you set the size of the component after
  15. // you add any child components.
  16. setSize (800, 600);
  17. setFramesPerSecond (60); // This sets the frequency of the update calls.
  18. }
  19. ~%%content_component_class%%() override
  20. {
  21. }
  22. //==============================================================================
  23. void update() override
  24. {
  25. // This function is called at the frequency specified by the setFramesPerSecond() call
  26. // in the constructor. You can use it to update counters, animate values, etc.
  27. }
  28. //==============================================================================
  29. void paint (juce::Graphics& g) override
  30. {
  31. // (Our component is opaque, so we must completely fill the background with a solid colour)
  32. g.fillAll (getLookAndFeel().findColour (juce::ResizableWindow::backgroundColourId));
  33. // You can add your drawing code here!
  34. }
  35. void resized() override
  36. {
  37. // This is called when the MainContentComponent is resized.
  38. // If you add any child components, this is where you should
  39. // update their positions.
  40. }
  41. private:
  42. //==============================================================================
  43. // Your private member variables go here...
  44. JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (%%content_component_class%%)
  45. };