157e2f323SJérôme Duval/*
257e2f323SJérôme Duval * Copyright 2005, J��r��me Duval. All rights reserved.
357e2f323SJérôme Duval * Distributed under the terms of the MIT License.
457e2f323SJérôme Duval *
557e2f323SJérôme Duval * Inspired by SoundCapture from Be newsletter (Media Kit Basics: Consumers and Producers)
657e2f323SJérôme Duval */
757e2f323SJérôme Duval
857e2f323SJérôme Duval#include "RecorderApp.h"
957e2f323SJérôme Duval#include "RecorderWindow.h"
1057e2f323SJérôme Duval
1157e2f323SJérôme Duval
12ad0c65eaSJérôme DuvalRecorderApp::RecorderApp(const char* signature)
13ad0c65eaSJérôme Duval	: BApplication(signature), fRecorderWin(NULL)
1457e2f323SJérôme Duval{
155fa77532SJérôme Duval	fRecorderWin = new RecorderWindow();
1657e2f323SJérôme Duval}
1757e2f323SJérôme Duval
18ad0c65eaSJérôme Duval
1957e2f323SJérôme DuvalRecorderApp::~RecorderApp()
2057e2f323SJérôme Duval{
2157e2f323SJérôme Duval}
2257e2f323SJérôme Duval
2357e2f323SJérôme Duval
245fa77532SJérôme Duvalstatus_t
255fa77532SJérôme DuvalRecorderApp::InitCheck()
2657e2f323SJérôme Duval{
275fa77532SJérôme Duval	if (fRecorderWin)
285fa77532SJérôme Duval		return fRecorderWin->InitCheck();
295fa77532SJérôme Duval	return B_OK;
3057e2f323SJérôme Duval}
3157e2f323SJérôme Duval
3257e2f323SJérôme Duval
3357e2f323SJérôme Duvalint
3457e2f323SJérôme Duvalmain()
3557e2f323SJérôme Duval{
3657e2f323SJérôme Duval	RecorderApp app("application/x-vnd.Haiku-SoundRecorder");
375fa77532SJérôme Duval	if (app.InitCheck() == B_OK)
385fa77532SJérôme Duval		app.Run();
3957e2f323SJérôme Duval	return 0;
405fa77532SJérôme Duval}
41