I recently ran into a bug that took me a good two days of trial and error to figure out.
I’ve found that when my DocumentWindow component calls setUsingNativeTitleBar( true ) that QuickTimeMovieComponents no longer show in the main component
MainWindow::MainWindow()
: DocumentWindow (T("Main Window"),
Colours::white,
DocumentWindow::allButtons,
true)
{
setResizable (true, false); // resizability is a property of ResizableWindow
setResizeLimits (500, 500, 8192, 8192);
setContentComponent ( new MainComponent() );
setVisible ( true );
setUsingNativeTitleBar( true );
}
class MainComponent : public Component
{
public:
MainComponent();
~MainComponent();
void resized();
private:
QuickTimeMovieComponent mMoviePlayer;
};
MainComponent::MainComponent ()
: Component (T("Main Component"))
{
addAndMakeVisible( &mMoviePlayer );
setSize (1200, 800);
}
MainComponent::~MainComponent ()
{
}
MainComponent::resized()
{
mMoviePlayer.setBounds( 10, 10, 400, 400 );
}
I’m using Windows XP, the Quicktime 7 SDK and Visual Studio 2008.
It doesn’t look like anyone has had this problem previously.
Any ideas why it breaks?