ScreenSaverWindow::ScreenSaverWindow() : BWindow(BRect(50.0f, 50.0f, 50.0f + kWindowWidth, 50.0f + kWindowHeight), B_TRANSLATE_SYSTEM_NAME("ScreenSaver"), B_TITLED_WINDOW, B_ASYNCHRONOUS_CONTROLS | B_AUTO_UPDATE_SIZE_LIMITS) { fSettings.Load(); fMinWidth = floorf(be_control_look->DefaultItemSpacing() * (kWindowWidth / kDefaultItemSpacingAt12pt)); font_height fontHeight; be_plain_font->GetHeight(&fontHeight); float textHeight = ceilf(fontHeight.ascent + fontHeight.descent); fMinHeight = ceilf(std::max(kWindowHeight, textHeight * 28)); // Create the password editing window fPasswordWindow = new PasswordWindow(fSettings); fPasswordWindow->Run(); // Create the tab view fTabView = new TabView(); fTabView->SetBorder(B_NO_BORDER); // Create the controls inside the tabs fFadeView = new FadeView(B_TRANSLATE("General"), fSettings); fModulesView = new ModulesView(B_TRANSLATE("Screensavers"), fSettings); fTabView->AddTab(fFadeView); fTabView->AddTab(fModulesView); // Create the topmost background view BView* topView = new BView("topView", B_WILL_DRAW); topView->SetViewUIColor(B_PANEL_BACKGROUND_COLOR); topView->SetExplicitAlignment(BAlignment(B_ALIGN_USE_FULL_WIDTH, B_ALIGN_USE_FULL_HEIGHT)); topView->SetExplicitMinSize(BSize(fMinWidth, fMinHeight)); BLayoutBuilder::Group<>(topView, B_VERTICAL) .SetInsets(0, B_USE_DEFAULT_SPACING, 0, B_USE_WINDOW_SPACING) .Add(fTabView) .End(); SetLayout(new BGroupLayout(B_VERTICAL)); GetLayout()->AddView(topView); fTabView->Select(fSettings.WindowTab()); if (fSettings.WindowFrame().left > 0 && fSettings.WindowFrame().top > 0) MoveTo(fSettings.WindowFrame().left, fSettings.WindowFrame().top); if (fSettings.WindowFrame().Width() > 0 && fSettings.WindowFrame().Height() > 0) { ResizeTo(fSettings.WindowFrame().Width(), fSettings.WindowFrame().Height()); } CenterOnScreen(); }
ScreenSaverWindow::ScreenSaverWindow() : BWindow(BRect(50, 50, 496, 375), B_TRANSLATE_SYSTEM_NAME("ScreenSaver"), B_TITLED_WINDOW, B_ASYNCHRONOUS_CONTROLS | B_AUTO_UPDATE_SIZE_LIMITS) { fSettings.Load(); float spacing = be_control_look->DefaultItemSpacing(); fMinWidth = ceilf(std::max(446.0f, spacing * 44.6f)); fMinHeight = ceilf(std::max(325.0f, spacing * 32.5f)); // Create the password editing window fPasswordWindow = new PasswordWindow(fSettings); fPasswordWindow->Run(); // Create the tab view fTabView = new BTabView("tab_view", B_WIDTH_FROM_LABEL); // Create the controls inside the tabs fFadeView = new FadeView(B_TRANSLATE("General"), fSettings); fModulesView = new ModulesView(B_TRANSLATE("Screensavers"), fSettings); fTabView->AddTab(fFadeView); fTabView->AddTab(fModulesView); // Create the topmost background view BView* topView = new BView("topView", B_WILL_DRAW); topView->SetViewColor(ui_color(B_PANEL_BACKGROUND_COLOR)); topView->SetExplicitAlignment(BAlignment(B_ALIGN_USE_FULL_WIDTH, B_ALIGN_USE_FULL_HEIGHT)); topView->SetExplicitMinSize(BSize(fMinWidth, fMinHeight)); BLayoutBuilder::Group<>(topView, B_VERTICAL) .SetInsets(-1, B_USE_SMALL_SPACING, -1, -1) .Add(fTabView) .End(); SetLayout(new BGroupLayout(B_VERTICAL)); GetLayout()->AddView(topView); fTabView->Select(fSettings.WindowTab()); if (fSettings.WindowFrame().left > 0 && fSettings.WindowFrame().top > 0) MoveTo(fSettings.WindowFrame().left, fSettings.WindowFrame().top); if (fSettings.WindowFrame().Width() > 0 && fSettings.WindowFrame().Height() > 0) { ResizeTo(fSettings.WindowFrame().Width(), fSettings.WindowFrame().Height()); } }
ApplicationTypeWindow::ApplicationTypeWindow(BPoint position, const BEntry& entry) : BWindow(BRect(0.0f, 0.0f, 250.0f, 340.0f).OffsetBySelf(position), B_TRANSLATE("Application type"), B_TITLED_WINDOW, B_NOT_ZOOMABLE | B_ASYNCHRONOUS_CONTROLS | B_FRAME_EVENTS | B_AUTO_UPDATE_SIZE_LIMITS), fChangedProperties(0) { float padding = be_control_look->DefaultItemSpacing(); BAlignment labelAlignment = be_control_look->DefaultLabelAlignment(); BMenuBar* menuBar = new BMenuBar((char*)NULL); menuBar->SetExplicitAlignment(BAlignment(B_ALIGN_LEFT, B_ALIGN_TOP)); BMenu* menu = new BMenu(B_TRANSLATE("File")); fSaveMenuItem = new BMenuItem(B_TRANSLATE("Save"), new BMessage(kMsgSave), 'S'); fSaveMenuItem->SetEnabled(false); menu->AddItem(fSaveMenuItem); BMenuItem* item; menu->AddItem(item = new BMenuItem( B_TRANSLATE("Save into resource file" B_UTF8_ELLIPSIS), NULL)); item->SetEnabled(false); menu->AddSeparatorItem(); menu->AddItem(new BMenuItem(B_TRANSLATE("Close"), new BMessage(B_QUIT_REQUESTED), 'W', B_COMMAND_KEY)); menuBar->AddItem(menu); // Signature fSignatureControl = new BTextControl(B_TRANSLATE("Signature:"), NULL, new BMessage(kMsgSignatureChanged)); fSignatureControl->SetModificationMessage( new BMessage(kMsgSignatureChanged)); // filter out invalid characters that can't be part of a MIME type name BTextView* textView = fSignatureControl->TextView(); textView->SetMaxBytes(B_MIME_TYPE_LENGTH); const char* disallowedCharacters = "<>@,;:\"()[]?="; for (int32 i = 0; disallowedCharacters[i]; i++) { textView->DisallowChar(disallowedCharacters[i]); } // "Application Flags" group BBox* flagsBox = new BBox("flagsBox"); fFlagsCheckBox = new BCheckBox("flags", B_TRANSLATE("Application flags"), new BMessage(kMsgToggleAppFlags)); fFlagsCheckBox->SetValue(B_CONTROL_ON); fSingleLaunchButton = new BRadioButton("single", B_TRANSLATE("Single launch"), new BMessage(kMsgAppFlagsChanged)); fMultipleLaunchButton = new BRadioButton("multiple", B_TRANSLATE("Multiple launch"), new BMessage(kMsgAppFlagsChanged)); fExclusiveLaunchButton = new BRadioButton("exclusive", B_TRANSLATE("Exclusive launch"), new BMessage(kMsgAppFlagsChanged)); fArgsOnlyCheckBox = new BCheckBox("args only", B_TRANSLATE("Args only"), new BMessage(kMsgAppFlagsChanged)); fBackgroundAppCheckBox = new BCheckBox("background", B_TRANSLATE("Background app"), new BMessage(kMsgAppFlagsChanged)); flagsBox->AddChild(BGridLayoutBuilder() .Add(fSingleLaunchButton, 0, 0).Add(fArgsOnlyCheckBox, 1, 0) .Add(fMultipleLaunchButton, 0, 1).Add(fBackgroundAppCheckBox, 1, 1) .Add(fExclusiveLaunchButton, 0, 2) .SetInsets(padding, padding, padding, padding)); flagsBox->SetLabel(fFlagsCheckBox); // "Icon" group BBox* iconBox = new BBox("IconBox"); iconBox->SetLabel(B_TRANSLATE("Icon")); fIconView = new IconView("icon"); fIconView->SetModificationMessage(new BMessage(kMsgIconChanged)); iconBox->AddChild(BGroupLayoutBuilder(B_HORIZONTAL) .Add(fIconView) .SetInsets(padding, padding, padding, padding)); // "Supported Types" group BBox* typeBox = new BBox("typesBox"); typeBox->SetLabel(B_TRANSLATE("Supported types")); fTypeListView = new SupportedTypeListView("Suppported Types", B_SINGLE_SELECTION_LIST); fTypeListView->SetSelectionMessage(new BMessage(kMsgTypeSelected)); BScrollView* scrollView = new BScrollView("type scrollview", fTypeListView, B_FRAME_EVENTS | B_WILL_DRAW, false, true); fAddTypeButton = new BButton("add type", B_TRANSLATE("Add" B_UTF8_ELLIPSIS), new BMessage(kMsgAddType)); fRemoveTypeButton = new BButton("remove type", B_TRANSLATE("Remove"), new BMessage(kMsgRemoveType)); fTypeIconView = new IconView("type icon"); BView* iconHolder = BGroupLayoutBuilder(B_HORIZONTAL).Add(fTypeIconView); fTypeIconView->SetModificationMessage(new BMessage(kMsgTypeIconsChanged)); typeBox->AddChild(BGridLayoutBuilder(padding, padding) .Add(scrollView, 0, 0, 1, 4) .Add(fAddTypeButton, 1, 0, 1, 2) .Add(fRemoveTypeButton, 1, 2, 1, 2) .Add(iconHolder, 2, 1, 1, 2) .SetInsets(padding, padding, padding, padding) .SetColumnWeight(0, 3) .SetColumnWeight(1, 2) .SetColumnWeight(2, 1)); iconHolder->SetExplicitAlignment( BAlignment(B_ALIGN_CENTER, B_ALIGN_MIDDLE)); // "Version Info" group BBox* versionBox = new BBox("versionBox"); versionBox->SetLabel(B_TRANSLATE("Version info")); fMajorVersionControl = new BTextControl(B_TRANSLATE("Version:"), NULL, NULL); _MakeNumberTextControl(fMajorVersionControl); fMiddleVersionControl = new BTextControl(".", NULL, NULL); _MakeNumberTextControl(fMiddleVersionControl); fMinorVersionControl = new BTextControl(".", NULL, NULL); _MakeNumberTextControl(fMinorVersionControl); fVarietyMenu = new BPopUpMenu("variety", true, true); fVarietyMenu->AddItem(new BMenuItem(B_TRANSLATE("Development"), NULL)); fVarietyMenu->AddItem(new BMenuItem(B_TRANSLATE("Alpha"), NULL)); fVarietyMenu->AddItem(new BMenuItem(B_TRANSLATE("Beta"), NULL)); fVarietyMenu->AddItem(new BMenuItem(B_TRANSLATE("Gamma"), NULL)); item = new BMenuItem(B_TRANSLATE("Golden master"), NULL); fVarietyMenu->AddItem(item); item->SetMarked(true); fVarietyMenu->AddItem(new BMenuItem(B_TRANSLATE("Final"), NULL)); BMenuField* varietyField = new BMenuField("", fVarietyMenu); fInternalVersionControl = new BTextControl("/", NULL, NULL); fShortDescriptionControl = new BTextControl(B_TRANSLATE("Short description:"), NULL, NULL); // TODO: workaround for a GCC 4.1.0 bug? Or is that really what the standard says? version_info versionInfo; fShortDescriptionControl->TextView()->SetMaxBytes( sizeof(versionInfo.short_info)); BStringView* longLabel = new BStringView(NULL, B_TRANSLATE("Long description:")); longLabel->SetExplicitAlignment(labelAlignment); fLongDescriptionView = new TabFilteringTextView("long desc"); fLongDescriptionView->SetMaxBytes(sizeof(versionInfo.long_info)); scrollView = new BScrollView("desc scrollview", fLongDescriptionView, B_FRAME_EVENTS | B_WILL_DRAW, false, true); // TODO: remove workaround (bug #5678) BSize minScrollSize = scrollView->ScrollBar(B_VERTICAL)->MinSize(); minScrollSize.width += fLongDescriptionView->MinSize().width; scrollView->SetExplicitMinSize(minScrollSize); versionBox->AddChild(BGridLayoutBuilder(padding / 2, padding) .Add(fMajorVersionControl->CreateLabelLayoutItem(), 0, 0) .Add(fMajorVersionControl->CreateTextViewLayoutItem(), 1, 0) .Add(fMiddleVersionControl, 2, 0, 2) .Add(fMinorVersionControl, 4, 0, 2) .Add(varietyField, 6, 0, 3) .Add(fInternalVersionControl, 9, 0, 2) .Add(fShortDescriptionControl->CreateLabelLayoutItem(), 0, 1) .Add(fShortDescriptionControl->CreateTextViewLayoutItem(), 1, 1, 10) .Add(longLabel, 0, 2) .Add(scrollView, 1, 2, 10, 3) .SetInsets(padding, padding, padding, padding) .SetRowWeight(3, 3)); // put it all together SetLayout(new BGroupLayout(B_VERTICAL)); AddChild(menuBar); AddChild(BGroupLayoutBuilder(B_VERTICAL, padding) .Add(fSignatureControl) .Add(BGroupLayoutBuilder(B_HORIZONTAL, padding) .Add(flagsBox, 3) .Add(iconBox, 1)) .Add(typeBox) .Add(versionBox) .SetInsets(padding, padding, padding, padding)); SetKeyMenuBar(menuBar); fSignatureControl->MakeFocus(true); BMimeType::StartWatching(this); _SetTo(entry); }
BSCWindow::BSCWindow() : BDirectWindow(kWindowRect, "BeScreenCapture", B_TITLED_WINDOW, B_ASYNCHRONOUS_CONTROLS|B_AUTO_UPDATE_SIZE_LIMITS), fController(dynamic_cast<Controller*>(gControllerLooper)), fCapturing(false) { OutputView *outputView = new OutputView(fController); AdvancedOptionsView *advancedView = new AdvancedOptionsView(fController); fStartStopButton = new BButton("Start", "Start Recording", new BMessage(kMsgGUIStartCapture)); fStartStopButton->SetTarget(fController); fStartStopButton->SetExplicitAlignment(BAlignment(B_ALIGN_RIGHT, B_ALIGN_MIDDLE)); fCardLayout = new BCardLayout(); BView* cardsView = new BView("status", 0, fCardLayout); cardsView->SetViewColor(ui_color(B_PANEL_BACKGROUND_COLOR)); fCardLayout->AddView(fCamStatus = new CamStatusView("CamStatusView")); fCamStatus->SetExplicitAlignment(BAlignment(B_ALIGN_LEFT, B_ALIGN_MIDDLE)); BView* statusView = BLayoutBuilder::Group<>() .SetInsets(B_USE_DEFAULT_SPACING, B_USE_DEFAULT_SPACING, B_USE_DEFAULT_SPACING, B_USE_DEFAULT_SPACING) .AddGroup(B_HORIZONTAL, B_USE_DEFAULT_SPACING) .Add(fStringView = new BStringView("stringview", kEncodingString)) .Add(fStatusBar = new BStatusBar("", "")) .End() .View(); statusView->SetExplicitAlignment(BAlignment(B_ALIGN_LEFT, B_ALIGN_MIDDLE)); fStatusBar->SetExplicitMinSize(BSize(100, 20)); fCardLayout->AddView(statusView); BLayoutBuilder::Group<>(this, B_VERTICAL) .AddGroup(B_VERTICAL, 1) .SetInsets(B_USE_DEFAULT_SPACING, 1, B_USE_DEFAULT_SPACING, 1) .Add(fTabView = new BTabView("Tab View", B_WIDTH_FROM_LABEL)) .AddGroup(B_HORIZONTAL) .Add(cardsView) .Add(fStartStopButton) .End() .End(); fCardLayout->SetVisibleItem((int32)0); BGroupView* outputGroup = new BGroupView(B_HORIZONTAL); outputGroup->SetName("Output"); outputGroup->GroupLayout()->SetInsets(B_USE_DEFAULT_SPACING, B_USE_DEFAULT_SPACING, B_USE_DEFAULT_SPACING, B_USE_DEFAULT_SPACING); fTabView->AddTab(outputGroup); BLayoutBuilder::Group<>(outputGroup) .Add(outputView); BGroupView* advancedGroup = new BGroupView(B_HORIZONTAL); advancedGroup->SetName("Advanced Options"); advancedGroup->GroupLayout()->SetInsets(B_USE_DEFAULT_SPACING, B_USE_DEFAULT_SPACING, B_USE_DEFAULT_SPACING, B_USE_DEFAULT_SPACING); fTabView->AddTab(advancedGroup); BLayoutBuilder::Group<>(advancedGroup) .Add(advancedView); if (fController->LockLooper()) { // controller should watch for these messages //StartWatching(fController, kMsgGUIStartCapture); //StartWatching(fController, kMsgGUIStopCapture); StartWatching(fController, kSelectionWindowClosed); advancedView->StartWatching(fController, kClipSizeChanged); //StartWatching(fCamStatus, kMsgControllerCaptureResumed); // watch Controller for these fController->StartWatching(this, B_UPDATE_STATUS_BAR); fController->StartWatching(this, B_RESET_STATUS_BAR); fController->StartWatching(this, kMsgControllerEncodeStarted); fController->StartWatching(this, kMsgControllerEncodeProgress); fController->StartWatching(this, kMsgControllerEncodeFinished); fController->StartWatching(this, kMsgControllerTargetFrameChanged); fController->StartWatching(this, kMsgControllerCaptureStarted); fController->StartWatching(this, kMsgControllerCaptureStopped); fController->StartWatching(fCamStatus, kMsgControllerCaptureStarted); fController->StartWatching(fCamStatus, kMsgControllerCaptureStopped); fController->StartWatching(fCamStatus, kMsgControllerCapturePaused); fController->StartWatching(fCamStatus, kMsgControllerCaptureResumed); fController->StartWatching(outputView, kMsgControllerTargetFrameChanged); fController->StartWatching(outputView, kMsgControllerCodecListUpdated); fController->UnlockLooper(); } StartWatching(outputView, kSelectionWindowClosed); StartWatching(outputView, kClipSizeChanged); CenterOnScreen(); }
MediaConverterWindow::MediaConverterWindow(BRect frame) : BWindow(frame, B_TRANSLATE_SYSTEM_NAME("MediaConverter"), B_TITLED_WINDOW_LOOK, B_NORMAL_WINDOW_FEEL, B_NOT_ZOOMABLE | B_NOT_V_RESIZABLE | B_ASYNCHRONOUS_CONTROLS | B_AUTO_UPDATE_SIZE_LIMITS), fVideoQuality(75), fAudioQuality(75), fSaveFilePanel(NULL), fOpenFilePanel(NULL), fOutputDirSpecified(false), fEnabled(true), fConverting(false), fCancelling(false) { BPath outputDir; if (find_directory(B_USER_DIRECTORY, &outputDir) != B_OK) outputDir.SetTo("/boot/home"); fOutputDir.SetTo(outputDir.Path()); fMenuBar = new BMenuBar("menubar"); _CreateMenu(); float padding = be_control_look->DefaultItemSpacing(); fListView = new MediaFileListView(); fListView->SetExplicitMinSize(BSize(padding * kMinSourceWidth, B_SIZE_UNSET)); BScrollView* scroller = new BScrollView(NULL, fListView, 0, false, true); // file list view box fSourcesBox = new BBox(B_FANCY_BORDER, scroller); fSourcesBox->SetLayout(new BGroupLayout(B_HORIZONTAL, 0)); // fSourcesBox's layout adjusted in _UpdateLabels // info box fInfoView = new MediaFileInfoView(); fInfoView->SetExplicitAlignment(BAlignment(B_ALIGN_USE_FULL_WIDTH, B_ALIGN_VERTICAL_UNSET)); fInfoBox = new BBox(B_FANCY_BORDER, fInfoView); // output menu fields fFormatMenu = new BMenuField(NULL, B_TRANSLATE("File format:"), new BPopUpMenu("")); fAudioMenu = new BMenuField(NULL, B_TRANSLATE("Audio encoding:"), new BPopUpMenu("")); fVideoMenu = new BMenuField(NULL, B_TRANSLATE("Video encoding:"), new BPopUpMenu("")); // output folder fDestButton = new BButton(B_TRANSLATE("Output folder"), new BMessage(OUTPUT_FOLDER_MESSAGE)); BAlignment labelAlignment(be_control_look->DefaultLabelAlignment()); fOutputFolder = new BStringView(NULL, outputDir.Path()); fOutputFolder->SetExplicitAlignment(labelAlignment); // start/end duration fStartDurationTC = new BTextControl(NULL, "0", NULL); BLayoutItem* startDuration = fStartDurationTC->CreateTextViewLayoutItem(); startDuration->SetExplicitSize(BSize(padding * kDurationWidth, B_SIZE_UNSET)); startDuration->SetExplicitAlignment(BAlignment(B_ALIGN_LEFT, B_ALIGN_VERTICAL_CENTER)); fEndDurationTC = new BTextControl(NULL, "0", NULL); BLayoutItem* endDuration = fEndDurationTC->CreateTextViewLayoutItem(); endDuration->SetExplicitSize(BSize(padding * kDurationWidth, B_SIZE_UNSET)); endDuration->SetExplicitAlignment(BAlignment(B_ALIGN_LEFT, B_ALIGN_VERTICAL_CENTER)); // video quality fVideoQualitySlider = new BSlider("VSlider", "" , new BMessage(VIDEO_QUALITY_CHANGED_MESSAGE), 1, 100, B_HORIZONTAL); fVideoQualitySlider->SetModificationMessage( new BMessage(VIDEO_QUALITY_CHANGED_MESSAGE)); fVideoQualitySlider->SetValue(fVideoQuality); fVideoQualitySlider->SetEnabled(false); fVideoQualitySlider->SetExplicitSize(BSize(padding * kQualitySliderWidth, B_SIZE_UNSET)); // audio quality fAudioQualitySlider = new BSlider("ASlider", "" , new BMessage(AUDIO_QUALITY_CHANGED_MESSAGE), 1, 100, B_HORIZONTAL); fAudioQualitySlider->SetModificationMessage( new BMessage(AUDIO_QUALITY_CHANGED_MESSAGE)); fAudioQualitySlider->SetValue(fAudioQuality); fAudioQualitySlider->SetEnabled(false); fAudioQualitySlider->SetExplicitSize(BSize(padding * kQualitySliderWidth, B_SIZE_UNSET)); // output format box BView* outputGrid = BLayoutBuilder::Grid<>() .Add(fFormatMenu->CreateLabelLayoutItem(), 0, 0) .Add(fFormatMenu->CreateMenuBarLayoutItem(), 1, 0) .Add(fAudioMenu->CreateLabelLayoutItem(), 0, 1) .Add(fAudioMenu->CreateMenuBarLayoutItem(), 1, 1) .Add(fVideoMenu->CreateLabelLayoutItem(), 0, 2) .Add(fVideoMenu->CreateMenuBarLayoutItem(), 1, 2) .Add(fDestButton, 0, 3) .Add(fOutputFolder, 1, 3) .Add(fStartDurationTC->CreateLabelLayoutItem(), 0, 4) .Add(startDuration, 1, 4) .Add(fEndDurationTC->CreateLabelLayoutItem(), 0, 5) .Add(endDuration, 1, 5) .Add(fVideoQualitySlider, 0, 6, 2, 1) .Add(fAudioQualitySlider, 0, 7, 2, 1) .View(); outputGrid->SetExplicitAlignment(BAlignment(B_ALIGN_USE_FULL_WIDTH, B_ALIGN_USE_FULL_HEIGHT)); fOutputBox = new OutputBox(B_FANCY_BORDER, outputGrid); fOutputBox->SetLayout(new BGroupLayout(B_HORIZONTAL, 0)); // fOutputBox's layout adjusted in _UpdateLabels // buttons fPreviewButton = new BButton(B_TRANSLATE("Preview"), new BMessage(PREVIEW_MESSAGE)); fPreviewButton->SetEnabled(false); fConvertButton = new BButton(B_TRANSLATE("Convert"), new BMessage(CONVERT_BUTTON_MESSAGE)); // Status views fStatus = new BStringView(NULL, NULL); fStatus->SetExplicitAlignment(labelAlignment); fFileStatus = new BStringView(NULL, NULL); fFileStatus->SetExplicitAlignment(labelAlignment); SetStatusMessage(""); _UpdateLabels(); BLayoutBuilder::Group<>(this, B_VERTICAL, 0) .SetInsets(0, 0, 0, 0) .Add(fMenuBar) .AddSplit(B_HORIZONTAL, padding / 2) .SetInsets(padding, padding, padding, padding) .Add(fSourcesBox, 0.4) .AddGroup(B_VERTICAL, padding, 0.6) .Add(fInfoBox) .Add(fOutputBox) .End() .End() .AddGrid(padding, padding) .SetInsets(padding, 0, padding, padding) .Add(fStatus, 0, 0) .Add(fFileStatus, 0, 1) .Add(BSpaceLayoutItem::CreateGlue(), 1, 0) .Add(fPreviewButton, 2, 0) .Add(fConvertButton, 3, 0) .End(); }